Hi all,
I'm starting to poke
about with landscapes again. I've mastered rendering a 32x32
heightmap. Last night, I figured out how to put in water, but I've still
got to make a test program to see if I've got it right. And I'm looking
forward to eventually getting a model walking across a scene.
I've a couple of FUDs
(Fear, Uncertainty, Doubt) about a few things, tho. I'm not sure how I can
use a quad-tree or oct-tree to do culling within a scene graph. I can
understand it in immedate mode. It seems to me that the Shape that I'd
create would have to be removed and rebuilt with each movement of the
camera. Even just panning from left to right would cause it. Doesn't
that create a lot of overhead? Or am I just not grasping it?
One way I though of
handling a large landscape was this: I would break my landscape data up
into cells. I would only load a few cells at a time, the cells the camera
is in and the adjacent ones. Something like this (gotta love ascii
art!):
[ ][ ][ ][ ][ ]
[ ][X][X][X][ ]
[ ][X][*][X][ ]
[ ][X][X][X][ ]
[ ][ ][ ][ ][ ]
[*] = the cell the camera is
in
[X] = adjacent cell
[ ] =
unloaded cell I was thinking that I
could use some sort of LOD routine, perhaps ROAM, to handle the loaded
cells. But that brings me back to the question of manipulating the Shape
I've loaded into the scene graph.
