Skip to content

Commit

Permalink
Merge pull request #5782 from fcayre/fix-polyline-collection
Browse files Browse the repository at this point in the history
Fix PolylineCollection indices arrays (#5538)
  • Loading branch information
mramato authored Sep 27, 2017
2 parents 0115e26 + 246969b commit fe84d8e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Change Log
* Added ability to add an animation to `ModelAnimationCollection` by its index. [#5815](https://github.com/AnalyticalGraphicsInc/cesium/pull/5815)
* Fixed a bug in `ModelAnimationCollection` that caused adding an animation by its name to throw an error. [#5815](https://github.com/AnalyticalGraphicsInc/cesium/pull/5815)
* Zoom about mouse now maintains camera heading, pitch, and roll [#4639](https://github.com/AnalyticalGraphicsInc/cesium/pull/5603)
* Fixed a bug in `PolylineCollection` preventing the display of more than 16K points in a single collection [#5538](https://github.com/AnalyticalGraphicsInc/cesium/pull/5782)

### 1.37 - 2017-09-01

Expand Down
3 changes: 3 additions & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ See [CONTRIBUTING.md](CONTRIBUTING.md) for details on how to contribute to Cesiu
* [William Wall](https://github.com/wallw-bits)
* [virtualcitySYSTEMS GmbH](https://www.virtualcitysystems.de)
* [Jannes Bolling](https://github.com/jbo023)
* [Logilab](https://www.logilab.fr/)
* [Florent Cayré](https://github.com/fcayre/)

## [Individual CLA](Documentation/Contributors/CLAs/individual-cla-agi-v1.0.txt)
* [Victor Berchet](https://github.com/vicb)
Expand Down Expand Up @@ -156,4 +158,5 @@ See [CONTRIBUTING.md](CONTRIBUTING.md) for details on how to contribute to Cesiu
* [Rishabh Shah](https://github.com/rms13)
* [Rudraksha Shah](https://github.com/Rudraksha20)
* [Cody Guldner](https://github.com/burn123)
* [Florent Cayré](https://github.com/fcayre)

4 changes: 2 additions & 2 deletions Source/Scene/PolylineCollection.js
Original file line number Diff line number Diff line change
Expand Up @@ -1457,7 +1457,7 @@ define([
for ( var j = 0; j < numberOfSegments; ++j) {
var segmentLength = segments[j] - 1.0;
for ( var k = 0; k < segmentLength; ++k) {
if (indicesCount + 4 >= CesiumMath.SIXTY_FOUR_KILOBYTES - 2) {
if (indicesCount + 4 > CesiumMath.SIXTY_FOUR_KILOBYTES) {
polyline._locatorBuckets.push({
locator : bucketLocator,
count : segmentIndexCount
Expand Down Expand Up @@ -1489,7 +1489,7 @@ define([
count : segmentIndexCount
});

if (indicesCount + 4 >= CesiumMath.SIXTY_FOUR_KILOBYTES - 2) {
if (indicesCount + 4 > CesiumMath.SIXTY_FOUR_KILOBYTES) {
vertexBufferOffset.push(0);
indices = [];
totalIndices.push(indices);
Expand Down

0 comments on commit fe84d8e

Please sign in to comment.