State of play: terrain rendering

Started by
8 comments, last by Darkbouncer4689 12 years, 8 months ago
Hi there :)

As a quick intro about me, I released a 3D RPG on Android using libgdx at the start of the year and I'm now looking into starting my next project, a 3D RPG on PC. I have a pretty good idea of the technical requirements and implementation for the engine, but one thing I'm unsure about is the state of play for terrain rendering. I've been out of the loop of modern engine-level game programming for a while now (though I have done high level game programming for a next-gen studio a few years back), and the last time I seriously looked into terrain rendering was when ROAM was the way to go. Since then, I'm pretty sure things have changed, so what I'm looking for is a discussion on what modern tech/approaches are available these days.

My ultimate goal is to have the terrain looking something like it does in the Unreal Engine (http://www.unrealeng...atures/terrain/) and I definitely want real-time LOD, but obviously as an indie it's way out of my price range. It would be Very Nice ™ if I could lift a module out of an open-source engine instead of reinventing the wheel (I'm happy open-sourcing my stuff too), but I'd still like some pointers to what modern games are using these days :)

Any recommendations/advice is very welcome.

ChasmLords is a multiplayer roguelike with faction based PvP and dungeon crawling. Join the beta at Chasmlords.com!

Advertisement
Based on the 7th screenshot of the Unreal Engine terrain I would assume they are doing adaptive LOD using a quadtree. This is a fairly easy way to implement terrain geometry.


Hi there :)

As a quick intro about me, I released a 3D RPG on Android using libgdx at the start of the year and I'm now looking into starting my next project, a 3D RPG on PC. I have a pretty good idea of the technical requirements and implementation for the engine, but one thing I'm unsure about is the state of play for terrain rendering. I've been out of the loop of modern engine-level game programming for a while now (though I have done high level game programming for a next-gen studio a few years back), and the last time I seriously looked into terrain rendering was when ROAM was the way to go. Since then, I'm pretty sure things have changed, so what I'm looking for is a discussion on what modern tech/approaches are available these days.

My ultimate goal is to have the terrain looking something like it does in the Unreal Engine (http://www.unrealeng...atures/terrain/) and I definitely want real-time LOD, but obviously as an indie it's way out of my price range. It would be Very Nice ™ if I could lift a module out of an open-source engine instead of reinventing the wheel (I'm happy open-sourcing my stuff too), but I'd still like some pointers to what modern games are using these days :)

Any recommendations/advice is very welcome.


ROAM is pretty much out anymore due to the CPU+Dynamic Vertex Buffer costs involved. Most terrain engines start with something along the lines of http://tulrich.com/geekstuff/chunklod.html which is old but still of relevance in the current implementations. Basically the big deal is avoiding transferring vertices to the video card constantly where as the chunked versions do bulk 1 time replacements. Variations and upgrades exist to use vertex shader interpolations between transitions to avoid popping, sub-patch refinements instead of fixed grids, and a couple other things I can't remember of the top of my head.
I suggest using clipmap terrain.
Looks very similar to what they are using, and is fairly simple to implement. It can give you extremely vast viewing distances.


Most types of terrains show no or little morphing.
But those with sharp peaks can. I know of no way around this with any LOD system.


L. Spiro

I restore Nintendo 64 video-game OST’s into HD! https://www.youtube.com/channel/UCCtX_wedtZ5BoyQBXEhnVZw/playlists?view=1&sort=lad&flow=grid


http://www.youtube.c...feature=related But those with sharp peaks can. I know of no way around this with any LOD system.


Hard to avoid with geoclipmaps, but easy with geomipmaps (or any "per chunk" lod). Calculate the max error for each lower lod per chunk, multiply with screen distance. If it has a sharp spike, it will end up always being rendered at high(est) detail (less radical settings will at least have the popping happen while the chunk is still far away).

The first thing to ask yourself is what kind of terrain you are going for. Small but fancy or potentially infinite? Or even more basic questions: heightmap or a flexible approach allowing for caves and overhangs (or a combination).

A current PC should have no trouble handling GeoMipMapped terrain of about 8192x8192. For anything larger I'd definitely with GeoClipMapping

Terrain using geomipmaps: http://festini.devic...oads/jstart.zip
Messy source: http://festini.devic...s/jstartsrc.zip
f@dzhttp://festini.device-zero.de
My approach to caves is to simply load a new terrain up-side down, and another on top of that right-side up.
It only requires that the author of the terrain system have enough foresight to realize to make terrain as an instancable class and not as some kind of global (shudder) “this is the terrain in this engine, live with it”.
If your terrain can be loaded with any transform, you can patch terrains together at all kinds of angles to get good-looking overhangs or whatever you need.


L. Spiro

I restore Nintendo 64 video-game OST’s into HD! https://www.youtube.com/channel/UCCtX_wedtZ5BoyQBXEhnVZw/playlists?view=1&sort=lad&flow=grid

Thanks for your replies! I'll investigate geomipmapping and geoclipmapping I think.

The quality of detail I'm going for is a good degree of realism from short to long distances. Detailed object groups like towns and other areas will probably be impostered at long range then streamed in as the player approaches.

ChasmLords is a multiplayer roguelike with faction based PvP and dungeon crawling. Join the beta at Chasmlords.com!

I'm interested in this topic as well but am a first timer at terrain rendering. Theres a lot of great content here, I'm going to read that chapter on geo clipmapping. Great videos as well. I have a few questions though.

Are geo clipmapping and geo mipmapping the best techniques out right now? (At least in terms of what an indie game developer can implement).

Also, if the game will have a lot of flat terrain, with maybe some slopes, slight curves, and rounded mountains, are these methods still the most efficient? I'm not sure what the overhead in these methods involve and am wondering if they are still good to implement for simpler terrain. I think the demo videos look amazing but I don't forsee users flying around in my game and thus wouldn't really see the incredible looking detailed mountain terrain in those videos.

Sorry for the lame questions, noob here, please forgive.

Thanks =)
As a first thing, let's try to nail the problem to the basics. Me and several other forum members stated this multiple times, even recently but it's worth being clear.

John Carmack, 2006, on terrain rendering methods
That's one of those things that for years I think most of the research that's gone into has been wasted. Geometry level of detail on terrain.. there have been thousands of papers written about it, and I honestly don't think it's all that important. The way the hardware works, you're so much better off setting down a static mesh that's all in vertex and index buffers, and just letting the hardware plow through it, rather than going through and having the CPU attempt to do some really clever cross blended interpolation of vertices.[/quote]Whatever an algorithm is "efficient" or not is nowadays largely irrelevant.

For the time being, I am more inclined to chunking than clipmaps. Whatever this comes via generic DLOD or by using GeoMipmapping is not a real concern. GMM is basically DLOD on reverse and does not guarantee performance improvement when dealing with high-energy signals. In the past, I have been pretty negative about that but I've changed my mind in the last years. With so much vertex transform power, the chance to incur in high-energy signals is limited. Therefore, GMM would be my first choice right now as it's the one requiring less work to implement.

To directly answer your question: both geo clipmaps and mipmas are the best around - in one way or the other, for all but the most specialized applications. GMM would manage your data just fine (it's basically best case) while clipmaps... they simply don't care in the first place.

Previously "Krohm"

Thanks Krohm. Very informative. I think I will start with geomipmaps and see how it goes =)

This topic is closed to new replies.

Advertisement