frenchtoast747/webgl-obj-loader

UV layout, error in the code.

dybiszb opened this issue · 2 comments

Hi there, I just spotted that (webgl-obj-loader.js; line 866):
_case layout.Layout.UV.key:
dataView.setFloat32(offset, this.textures[i * 2], true);
dataView.setFloat32(offset + 4, this.vertices[i * 2 + 1], true);

probably should look like
_case layout.Layout.UV.key:
dataView.setFloat32(offset, this.textures[i * 2], true);
dataView.setFloat32(offset + 4, this.textures[i * 2 + 1], true);

which seems to solve a small problem that I had with correct gBuffer mappings ; D

Thanks, @dybiszb, for finding the issue and reporting!

Fixed on master. I will be doing a release with the fix later on.

No problem - my pleasure ; )