PDA

View Full Version : Terrain drawing: Ideal quadtree size?



Structural
01-29-2003, 09:16 PM
This is perhaps not directly opengl related, but I'll give it a shot anyway.
I have started with my first terrain "engine" this week, and I got it so far that I can split it up in a quadtree and draw it as a vertex array. I haven't tested any FPS yet because I haven't written the frustum culling mechanism or FPS counter yet.
Each leaf in the quadtree has 32*32 heightpoints, resulting in about 2048 triangles being drawn per section. The whole map exists out of 32*32 leafs.
I feel that the amount of tris per leaf is WAY too much, but I want to be sure and like to hear from the experts on this subject what they believe (or have experienced) what the best amount of triangles per leaf is.

Thank you!

HamsterofDeath
01-29-2003, 09:39 PM
i'd say : test 50,100,200, and 500 tris per leaf.

i'm using 250, which seems to work fine (not to much overhead), and not to much polys drawn when only 1 is visible (2000 polys drawn if only 1 of them is visible is bad)

HamsterofDeath
01-29-2003, 09:44 PM
if you got 32*32*2048 polys, that makes 65536 triangles...
with 250 polys per leaf, that makes a tree-depth of 4, which should be less deep enough not to slow down the engine.