Some glb / glTF files result in an incorrect mesh

Issue #93 new
Former user created an issue

Hello, I am attempting to load this glb file using version 5.0.0-beta1. However it results in a wildly incorrect mesh for me. The file has been exported from blender using the attached blend file. Exporting the blend as a different file format (e.g. .obj) and loading that instead it looks fine. Using an online glTF viewer (https://gltf-viewer.donmccurdy.com/) we can see that the glb file itself is not corrupted or exported incorrectly from Blender, so the problem most likely lies with Assimp itself or this package.

Note that it does not seem to be an issue with all glb / glTF files, as the attached bookcase glb looks fine from what I can tell. I also take this as a sign that I am not messing up the indices or anything on my end.

I am only using the Triangulate option when importing.

Comments (2)

  1. Jan Selchow

    The Nuget Packet is quite out of date. Try cloning this repo directly and see if the error persists.

  2. Jesper Sporron

    Same on master, but now model which loaded fine on 5.0.0-beta1 now straight up crashes with a CLR error:

    Fatal error. Internal CLR error. (0x80131506)

    EDIT: This is caused by the Triangulate option as replacing it with None fixes this crash at least. The OP issue of incorrect meshes is not caused by Triangulate and still looks weird with None option.

    Seems like it might be some infinite loop somewhere as well? Loading a 200kb glb file uses almost 2gb of ram!

    Cause seems to be this function in MemoryHelper.cs

    I think this needs its own issue 😛

  3. Log in to comment