Compare commits

..

1 Commits

Author SHA1 Message Date
jjspace 51291baf36
Merge 841a4cf12a into bcc5ea383e 2025-11-14 14:23:35 -05:00
3 changed files with 462 additions and 678 deletions

View File

@ -7,8 +7,7 @@
#### Fixes :wrench: #### Fixes :wrench:
- Billboards using `imageSubRegion` now render as expected. [#12585](https://github.com/CesiumGS/cesium/issues/12585) - Billboards using `imageSubRegion` now render as expected. [#12585](https://github.com/CesiumGS/cesium/issues/12585)
- Improved scaling of SVGs in billboards [#13020](https://github.com/CesiumGS/cesium/issues/13020) - Improved scaling of SVGs in billboards [#TODO](https://github.com/CesiumGS/cesium/issues/TODO)
- Fixed unexpected outline artifacts around billboards [#13038](https://github.com/CesiumGS/cesium/issues/13038)
#### Additions :tada: #### Additions :tada:

View File

@ -122,8 +122,6 @@ TexturePacker.prototype._findNode = function (node, { width, height }) {
return node; return node;
} }
const borderPadding = this._borderPadding;
// Vertical split (childNode1 = left half, childNode2 = right half). // Vertical split (childNode1 = left half, childNode2 = right half).
if (widthDifference > heightDifference) { if (widthDifference > heightDifference) {
node.childNode1 = new TextureNode({ node.childNode1 = new TextureNode({
@ -132,18 +130,12 @@ TexturePacker.prototype._findNode = function (node, { width, height }) {
width, width,
height: nodeHeight, height: nodeHeight,
}); });
node.childNode2 = new TextureNode({
// Apply padding only along the vertical "cut". x: rectangle.x + width,
const widthDifferencePadded = widthDifference - borderPadding; y: rectangle.y,
width: widthDifference,
if (widthDifferencePadded > 0) { height: nodeHeight,
node.childNode2 = new TextureNode({ });
x: rectangle.x + width + borderPadding,
y: rectangle.y,
width: widthDifferencePadded,
height: nodeHeight,
});
}
return this._findNode(node.childNode1, { width, height }); return this._findNode(node.childNode1, { width, height });
} }
@ -155,19 +147,12 @@ TexturePacker.prototype._findNode = function (node, { width, height }) {
width: nodeWidth, width: nodeWidth,
height, height,
}); });
node.childNode2 = new TextureNode({
// Apply padding only along the horizontal "cut". x: rectangle.x,
const heightDifferencePadded = heightDifference - borderPadding; y: rectangle.y + height,
width: nodeWidth,
if (heightDifferencePadded > 0) { height: heightDifference,
node.childNode2 = new TextureNode({ });
x: rectangle.x,
y: rectangle.y + height + borderPadding,
width: nodeWidth,
height: heightDifferencePadded,
});
}
return this._findNode(node.childNode1, { width, height }); return this._findNode(node.childNode1, { width, height });
} }

File diff suppressed because it is too large Load Diff