I’ve been trying to look up guide lines for poly count and performance. I’m currently toying around with a submarine game where I need a large, high resolution plane as a water surface. It needs to have a high resolution of polygons so I can make wave forms in the mesh. I started with a grid plane of 100 x 100 rectangles in Blender. That’s 10,000 rectangles = 20,000 triangles. That resolution is a little rough though. So I made a new grid with 250 x 250 rectangles. That’s 125,000 triangles.
It was better, but to get a smooth wave movement over the gigantic size of the water surface I need I’d actually want to up it to 1000 x 1000 rectangles. That’s 2M(!!) triangles. Unreal will however import and load it into the scene. But I’m wondering if stressing the engine to the limits by just having what’s merely a visual effect in the scene. The water surface is basically going to be in the camera view no matter where you position yourself in the game.
Whatever guidlines for poly count and performance I can find seem pretty vauge. It’s like “try to keep poly count to a minimum”. Yeah, ok. But what’s maximum then? “Use agressive LOD where possible”. Ok, but since my mesh stretches for miles it will still always be too close to the camera for LOD to have any significant impact. “Try to divide large meshes”. I can see how that can be done with buildings and architecture. You could export the walls for a house in one mesh, and then another mesh for the roof etc. But I can’t really divide one continous surface.
So, is a single 2M triangle mesh reasonable or am I stressing the engine too much?
You don’t need a giant-mesh to do this. I use a 50x50 plane w/tessellation up close and it shows waves just fine. You only need to really have large detail nearer the camera.
As for guides on poly-count, whatever you need vs whatever the machine can render in a given time. I’m getting ~500-600K polys on the entire scene in/on a large open landscape w/lots of grass and tessellation for up-close detail. I’d say 2M for just-water is a likely overkill but I’m not a pro, maybe there’s a use-case for something like this but I can’t see it…
Some hardware (especially older hardware) doesn’t like more than 65534 vertices per draw call. Generally, a plane has slightly less than twice as many triangles as vertices, so keep it at or under 100,000 triangles per plane.
In general, the cost in modern graphics is not in vertex transform, unless you use geometry shaders and tesselation, or very heavy morphing/skinning for character meshes. Going over on vertex count is not the end of the world.
That being said, if you have triangles that are smaller than a single pixel on the screen, you’re probably doing it wrong (unless you’re Pixar.)
A good high-end goal is to aim for about 5 pixels per triangle; a lower-end goal is to aim for 50 pixels per triangle. Generate appropriate LODs to hit approximately that goal, and you’ll do fine.
For what it’s worth, you may want to look at the Landscape system in Unreal. Apply a water shader material on it, instead of a terrain material, and you will get a lot of the tesselation and LOD handling for free, and with the new dynamic landscape edit layers, you may be able to add the dynamic waves you need that way,