Tris count dependent on modeling tool

Unity iPhone is reporting a higher number of tris in the editor than in the modeling tool (like for example C4D).

This is because the editor reports the triangles actually sent to OpenGL. All triangles sent to OpenGL need to be continues in both 3D space and UV space. If they are not continues, additional (degenerate) triangles will be created to bind the ‘triangle strips’ together. This is why the number is higher. (correct me if I am wrong)

When importing a mesh into unity, unity optimizes the mesh and creates triangle strips for you.

Now for the question.
Is the final tris count modeling-tool dependent? The reason I ask is because if I create a simple cube in C4D and import it into Unity iPhone I get a tris count of 21. If I do the same from cheetah I get a tris count of 32.

Is there some special consideration the 3D artist should take into account when creating the mesh? (I know that the UV map will increase the tris count)

Hello!

Yes, its dependent of the tool the number of triangles.

The 3D artist should try to optimize the mesh as much as possible, for example using bumps when there are certain parts of the mesh that are not too notable.

But a cube is a cube is a cube, isn’t it? If it’s composed of 6 quads(12 faces), why would it matter which package it was made in?

It depends for example of the quality you are making the cube. so it shouldn’t necessary have the same polygons.

At least that’s what I think how it works on what I have done in maya :s

Actually, there are many ways that a 12-tri cube can be UV’d, this is why you’re having discrepancies. Some will default to unwrap, others will default to all 6 sides being full-page UV map (essentially doubling your count), etc.

In theory, nearly all editors will export the same mesh count, but you’ve got to be diligent as an artist to make sure you’ve manually unwrapped and optimized UV’s wherever possible.

Does someone know how to get the poly and vertex count in Unity?

I don’t know anything in unity then…

I would like to create some tools in Maya for helping and preventig the artist to resolve this problem…

Or does someone already did a viewer with this informations and I could load a FBX file in?

Just press the Stat button in the Game Viewer

Oh yeah once the simulation starts the button appear -__-…

Anyway, I did some test as you can see on the following picture and this is a a little difficult to understand.

  • The full smooth edge seems to help to the number of vertex.
  • but the number of Uvs doesn’t really help… If I create an uv mapping if on close element it will create more vertex than the default Cube in Maya -__-…
    Iam69 gave to me this url, but I finally don’t understand why a close uv element will create more vertex than an open one… O_o…

The ultimate question could be :
How should look my object and uvs mapping for getting a vertex count near the maya statistics?

And additional question :
What about an object with 2 UVs set for lightmapping??
Does it multiply the number of vertex? object?

The yellow color with show the more lowest vertex count.

Full Res : http://samavan.com/divershelp/Test_TriangleStrip_Cube_A001.jpg

Also note that Unity iPhone count the tris differently than Unity PC/Mac. (See post at the top)

Is it a good idea to let Unity triangulate the polygons, and not do this in the 3D tool?

Or is there a tool we can use to optimize a mesh for real time engines?

Hello, as far as I know, there is no tool for optimizing a mesh, or if there is one, I dont think that will optimize it as much as your modeler can.

So, the best optimization you can achieve on a mesh, depends entirely of your modeler skills.

The trouble when you have no UV separation whatsoever is that it is difficult to build a continuous strip. Think of UV seams as “guides” for strip generation. When there are no seams, you could go tons of different directions to build the next triangle, so it’s likely you end up in more “trap” spots, surrounded by already computed triangles, where it must create a degenerate triangle in order to move to the next triangle.

  1. Don’t.
  2. Don’t Yet (for experts only).

Unless you have something that is completely out of control, I wouldn’t worry about it too much. Generally, smooth edges wherever possible, keep UVs in big continuous shells wherever possible. If you’re doing that, then you are getting the most bang for your buck. Anything more and you’re probably wasting time.

Unity allows each vertex to have 2 UVs at no additional expense. As long as your UV seams in your second UV set are the same as or less than they are in the first, you will generate no additional vertices. If you have more or different seams, you will generate additional vertices.