managing huge map

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
paooolino
Posts: 50
Joined: Wed Dec 21, 2005 12:17 pm
Location: Brescia, Italy
Contact:

managing huge map

Post by paooolino »

Hello everybody. I was wondering on how to make and render a really big map.
I'm not going to use the TerrainSceneNode but a simple mesh for the terrain. The problem is all the amount of objects (trees, houses, stuffs, etc) contained in the map.
I was thinking about making two (or three) versions of each object (from hi-poly to low-poly) loading low poly models for far objects.

Any suggestion?
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

Your plans for LOD (level of detail) for the meshes is a good one.

There are other options for rendering large terrains well, you could use Arras' tiled terrain scene node which apparently renders large terrains very well, there's also some other attempts at achieving this, all should be able to be found in the projects forum.

Nadro has also, just today, posted his first version of occlusion culling for irrlicht (no source yet) which could improve performance for large maps (though may not be as useful for large open maps as it would be for enclosed maps), so that could be something to keep an eye on.
Image Image Image
Mag-got
Posts: 42
Joined: Tue Dec 04, 2007 5:53 pm

Post by Mag-got »

Just a question, should the LOD mesh be changed by checking the distance all the time and when enough, change?
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

Checking every frame could be a bit much if you've got lots of objects to check i suppose... You could probably get away with doing it every few frames, maybe even 10 or 20 frames or so depending on how quickly you're moving (though time based would probably be better so it's not reliant on the framerate). And you could probably split up the objects so one frame you check the first X objects, then the next frame you check the next X objects and so on...
Image Image Image
paooolino
Posts: 50
Joined: Wed Dec 21, 2005 12:17 pm
Location: Brescia, Italy
Contact:

Post by paooolino »

..or dividing map into regions and simply checking in which region the player is at every frame, and then updating the LODs of meshes in each region ;)
maitrelame2
Posts: 26
Joined: Sun Jan 21, 2007 9:11 pm

Post by maitrelame2 »

Just like my terrain engine ^^
I guess it would be much easier to use a terrain Scene Node to do so, because a mesh is an unique entity and if you load the whole huge mesh at once you are going to have a really large amount of ram full and your render will be slow. You should split the map into small regions and load them when you are close, once you get far from it you just remove it.
Irrlicht 4ever.
3DModelerMan
Posts: 1691
Joined: Sun May 18, 2008 9:42 pm

billboard

Post by 3DModelerMan »

I'm more an artist, so polycount stuff is my thing. You could probably even do a billboard imposter system for when it's REALLY far away but still in veiw. :D
That would be illogical captain...

My first full game:
http://www.kongregate.com/games/3DModel ... tor#tipjar
Post Reply