mirror of https://github.com/CesiumGS/cesium.git
Compare commits
1 Commits
069b594fba
...
51291baf36
| Author | SHA1 | Date |
|---|---|---|
|
|
51291baf36 |
|
|
@ -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:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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
Loading…
Reference in New Issue