Sign in to follow this  
paic

Toroidal addressing in terrain rendering

Recommended Posts

Hi, Some days ago, I found a paper from Hugues Hoppe (Geometry clipmaps: Terrain rendering using nested regular grids) But I got stuck with something my brain don't want to understand : "Toroidal Adressing" ... I understand the idea (modulo addressing) but in this paper and the other related ones found in the reference, I didn't find any usefull information on a practical implementation. So, if someone has an idea on how this thing works, he(she) would be nice to explain it to me ^__^ .:: Paic Citron ::.

Share this post


Link to post
Share on other sites
He actually explains it right where he defines it (though it took me a few times reading his paper to notice):

"...with 2D wraparound addressing using mod operations on x and y"

So, basically, you take the size of your clipmap buffer (sizeOfClipmap), and enter coordinates into the clipmap as such:


xClip = xWorld % sizeOfClipmap
yClip = yWorld % sizeOfClipmap


It's really as simple as that :)

Share this post


Link to post
Share on other sites
I understand now : I'm just dumb ^^ I tried to understand starting from a wrong example, but now I understand well. I think I also need to store the coordinates of the clipmap's center to now where the clip region is, because of the modulo.

Thx again ^^

.:: Paic Citron ::.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this