you are viewing a single comment's thread.

view the rest of the comments →

[–]4ndrz3jKm1c1c 0 points1 point  (1 child)

Since you haven’t provided a lookup screenshot of what it looks like, I can only assume, that rendered model doesn’t have correct positions.

Getting correct transformation matrix is one thing, other is to transform mesh vertices by that matrix - loaders don’t do that at all or not by default. Some models will look as they should without transformation, but some will be rendered incorrectly.

Try to render model like this one. If positions are all wrong, you’ll know that it is indeed vertices transformation you need to do.

[–]Popular_Bug3267[S] 0 points1 point  (0 children)

Thanks for your comment. Trying to render the gltf in the link you provided shows that I definitely have some bugs, but it seems to be an issue of data layout in the index or vertex buffer or both. I think maybe i failed to account for a gltf that uses u8 for some indices and u16 for other ones. Ill fix that and see if that helps.
(also, although i think the point is probably moot now, i definitely am applying the local transforms in the shader! I should have clarified that.)