cesium-native icon indicating copy to clipboard operation
cesium-native copied to clipboard

Fix problems with QuantizedMeshLoader-generated glTFs

Open kring opened this issue 2 years ago • 0 comments

Before this PR, the glTFs generated from quantized-mesh tiles were technically invalid. Our game engine clients weren't too fussed about these problems, which is why we didn't notice.

Fixed the following problems:

  • The asset.version field was not set.
  • The byteLength of the buffers was not set. Most clients just used cesium.data.size() anyway.
  • The target type of the bufferView used to store indices was incorrectly set to ARRAY_BUFFER instead of ELEMENT_ARRAY_BUFFER.
  • The bufferView used to store indices had its byteStride property set, which is not allowed.
  • The glTF did not have any scenes.

kring avatar Mar 06 '24 05:03 kring