Skip to content

Commit 33c58e4

Browse files
committed
Base clippingPolygonsState field on collection length
1 parent 2e47068 commit 33c58e4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

packages/engine/Source/Scene/ClippingPolygonCollection.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ Object.defineProperties(ClippingPolygonCollection.prototype, {
330330
/**
331331
* Returns a number encapsulating the state for this ClippingPolygonCollection.
332332
*
333-
* Clipping mode is encoded in the sign of the number, which is just the total position count.
333+
* Clipping mode is encoded in the sign of the number, and the magnitude is the polygon count.
334334
* If this value changes, then shader regeneration is necessary.
335335
*
336336
* @memberof ClippingPolygonCollection.prototype
@@ -340,7 +340,7 @@ Object.defineProperties(ClippingPolygonCollection.prototype, {
340340
*/
341341
clippingPolygonsState: {
342342
get: function () {
343-
return this.inverse ? -this.extentsCount : this.extentsCount;
343+
return this.inverse ? -this.length : this.length;
344344
},
345345
},
346346
});

0 commit comments

Comments
 (0)