A good heightmap LOD technique (no VTF please)

Started by
27 comments, last by skytiger 12 years, 1 month ago

In that case, what are the 8 segments that you split a disk into?


The vertex buffer is "all terrain"
The disk is "potentially visible terrain"
The segments are "visible terrain"

By intersecting the view frustum with the segments you can render only the segments that are visible.

You can also use a draw call per segment and using the startindex and primcount to render only the visible depth band
This can handle degenerate case of camera pointing straight down (requiring small depth range of all 8 segments)
Also consider using a "plug" for the inner disk to simplify things.
Advertisement
[Doh, when I said geomipmapping in my previous posts i meant geoclipmapping]

What I meant was, what are the actual shapes of the 8 segments. Are you using the same shapes as for geoclipmapping? The blocks, fixup and interior segments like here:
gpugcm.mid.jpg
No, I am using "pizza slices" similar to my XNA Large Terrain

terraintransforms.png?w=512

But using 8 slices (instead of 16) to simplify things (and keep straight edges for all segments)

There are no "fix ups" as the LOD is static, again same as my other system:

terrainvertextexela1.png?w=780

(ignore the catmull rom stuff)

I've managed to build a working implementation using SlimDX (9) today
it proves the concept - tomorrow I will finish the index buffer builder
and then it only needs frustum intersection and its done
Ah so the slices look like this?
2l9gm14.jpg

And also, this means you can't do any kind of interpolation correct? You just "point sample" the vertex grid.
exactly
using PC DX9 I can't think of a way to perform interpolation
on XBOX DX9 you could vfetch and interpolate
(but the high quality LOD level reaches further)
I'm loving this topic, keep it up guys.

Cheers

Lee

Code is Life
C/C++, ObjC Programmer, 3D Artist, Media Production

Website : www.leestripp.com
Skype : lee.stripp@bigpond.com
Gmail : leestripp@gmail.com

I almost finished the index buffer builder today

terrainnewa.png

(edit) some stats: with LOD0 = 16x16 squares and a LOD pattern: 0, 1, 2, 3, 3, 4, 4, 4 the draw distance is 256 height samples and total triangles is 67,392 // absolute max tris drawn at one time is less than half that: 33,696 // all seems very reasonable to me
there is a hard cap on the size of height data of 2048x2048 (2^32) // which is maximum value of 32 bit index // although you could probably use multiple vertex buffers

vertexdata = 1024x1024 vertices @ 16 bytes each (ushort4 + ushort4) = 16MiB
indexdata = < 1MiB

whilst this technique is useful for SM2.0 it pales in comparison to my SM3.0 VTF technique - that supports heightmaps of 8192x8192 (Alpha8) with catmull-rom interpolation giving a virtual heightmap of 32768x32768 with all totally static data, no cpu usage, no streaming and only 4 draw calls
First run use BaseVertexIndex to follow the camera ...

[media]
[/media]

This topic is closed to new replies.

Advertisement