Do not take byte stride into account when it is zero. Although it is not valid according to the specification, it seems it can be handled as if byte stride was not specified.

This commit is contained in:
Viktor Kovacs 2021-04-20 18:55:32 +02:00
parent 2740de7098
commit 78460fe743

View File

@ -872,7 +872,7 @@ OV.ImporterGltf = class extends OV.ImporterBase
let reader = new OV.GltfBufferReader (buffer);
reader.SkipBytes (bufferView.byteOffset || 0);
let byteStride = bufferView.byteStride;
if (byteStride !== undefined) {
if (byteStride !== undefined && byteStride !== 0) {
reader.SetByteStride (byteStride);
}