Skip to content

Commit

Permalink
Merge pull request #6666 from AnalyticalGraphicsInc/batchid-uint32-fix
Browse files Browse the repository at this point in the history
Fix loading pnts tile with uint32 batch ids
  • Loading branch information
ggetz authored Jun 19, 2018
2 parents df17965 + e6673e2 commit 7f3fb3f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Change Log

##### Fixes :wrench:
* Fixed a bug causing crashes with custom vertex attributes on `Geometry` crossing the IDL. Attributes will be barycentrically interpolated. [#6644](https://github.com/AnalyticalGraphicsInc/cesium/pull/6644)
* Fixed a bug causing Point Cloud tiles with unsigned int batch-ids to not load. [#6666](https://github.com/AnalyticalGraphicsInc/cesium/pull/6666)
* Fixed a bug with Draco encoded i3dm tiles, and loading two Draco models with the same url. [#6668](https://github.com/AnalyticalGraphicsInc/cesium/issues/6668)

### 1.46.1 - 2018-06-01
Expand Down
5 changes: 4 additions & 1 deletion Source/Scene/PointCloud3DTileContent.js
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,10 @@ define([
var batchIds;
if (defined(featureTableJson.BATCH_ID)) {
batchIds = featureTable.getPropertyArray('BATCH_ID', ComponentDatatype.UNSIGNED_SHORT, 1);

if (ComponentDatatype.fromTypedArray(batchIds) === ComponentDatatype.UNSIGNED_INT) {
// WebGL does not support UNSIGNED_INT vertex attributes. Convert these to FLOAT.
batchIds = new Float32Array(batchIds);
}
var batchLength = featureTable.getGlobalProperty('BATCH_LENGTH');
if (!defined(batchLength)) {
throw new RuntimeError('Global property: BATCH_LENGTH must be defined when BATCH_ID is defined.');
Expand Down

0 comments on commit 7f3fb3f

Please sign in to comment.