- Home /
Best way to split up procedurally generated mesh
I have created a procedurally generated mesh, following Morten Nobel's tutorial. My mesh requires more than 65k vertices, which is a mesh generation limit (see here or here), so it must be split up. Some threads suggest to look into submeshes. But I am confused, what is the best way to split up a procedural mesh?
Since the number of vertices in my mesh is dynamic, should I check if vertices.count exceeds 65k, create a child gameobject with mesh Renderer & Filter, procedurally fill its mesh, then repeat if necessary? Or is there a better way?
As the linked thread explains, Submeshes are NOT a viable approach because they have nothing to do with the vertex limit, but rather with multiple materials on the same mesh.
So, yes, you have run a loop that splits your mesh until it is below the limit.
Your answer
