cesium-native
cesium-native copied to clipboard
Fix problems with QuantizedMeshLoader-generated glTFs
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.versionfield was not set. - The
byteLengthof the buffers was not set. Most clients just usedcesium.data.size()anyway. - The
targettype of the bufferView used to store indices was incorrectly set toARRAY_BUFFERinstead ofELEMENT_ARRAY_BUFFER. - The bufferView used to store indices had its
byteStrideproperty set, which is not allowed. - The glTF did not have any scenes.