- Home /
Empty triangles when loading 3D model with > 65.534 triangles
Dear Team,
I'm trying to load a 3D model (fbx or obj) with: (Vertices: 1.023.637; Triangles: 2.227.397)
Once I drag the 3D model to the scene visor in Unit3D, it consists of 34 submeshes (as much meshes as to complete the total number of triangles in the original mesh). Until here, everything is ok.
The problem is that once I observe the mesh, it appears like several triangles are empty, and this is not problem of the original mesh, since when visualizing it with a 3D viewer it is represented correctly.
Do you know what is happening? Could it be a problem in Unity3D when importing million vertices meshes?
Please help! Thank you very much!
I think individual mesh objects are capped at 65535 vertices. Common in graphics program$$anonymous$$g as it's cheaper to index with 16bit unsigned integers.
Yes, but once I import the 3D model to my scene, Unity correctly splits it correctly and automatically into 34 submeshes, so...it should work! However, several triangles appear empty...
Do you know what could happen?
Thanks!
Perhaps the missing triangles connect vertices that Unity has broken into separate submeshes? I guess that would be a bug, but if there are no seams to split on, then the importer will have to make some.
No, the observed empty triangles are distributed on all the mesh surface, without any order (apparently)...
Please, any solution?
I think i know what is happening. $$anonymous$$aybe the triangulation order of those 'empty' triangles is not correct. Is there any way to overcome this and show correctly the 3D model in Unity3D?
PS: If I use another viewer (not unity3D) the model is properly displayed, so I think this is because of the limitation of unity3D to consider very strictly the triangulation order of the facets...
Please, Help!
Answer by rutter · Sep 12, 2014 at 07:53 PM
For a single mesh in Unity, you're limited to 2^16
vertices, or 65536.
There is no explicit triangle limit, but if they're indexing tris with int32, which they seem to in the Mesh class, then there's an implicit limit at 2^32 / 3
, or 1431655765.
You can work around these limits by breaking your mesh into multiple objects, or by using simpler meshes. Both options will be much better for performance anyway, thanks to reduced number and complexity of draw calls.
Your answer
Follow this Question
Related Questions
Tool for exporting mesh to stl/obj/fbx in runtime(android) 0 Answers
problem in importing blender file to unity 2 Answers
Why does Unity use duplicate vertices in Mesh? 1 Answer
Maya LT - Export group as single FBX 0 Answers
Connecting flatshaded vertices 0 Answers