Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


N-Patches for terrain LOD

This topic is 6128 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, guys! Is somebody there who can help me ? (I apoligise, my english is probably awful, but I hope you''ll be able to understand me) I plan to implement a simple terrain rendering engine in my spare time with DirectX 8. My idea is to use n-patches for terrain LOD generation. Now, be patient and let me explain what is my problem: Ok, let''s say I know how to load a gray-scale bitmap from a file, generate a terrain mesh from it, and compute a quadtree for my visibility detection algorithm. My problem is how to produce various terrain LOD according to the distance from the camera using n-patches. An obvious solution is for every visible quadtree leaf to determine it''s distance to the observer and then compute the tesslation amount (number of segments) for that node, using a formula like this: NumSegments = ((MaxDistance - Distance) * MaxSegments + (Distance - MinDistance) * MinSegments) / (MaxDistance - MinDistance), where: Distance - the distance from the quadtree node to the camera, MinDistance - the distance to the near plane of my view frustum; MaxDistance - the distance to the far plane of my view frustum; MinSegments - the number of segments at the farthest distance; MaxSegments - the number of segments at the nearest distance. Probably the formula is not correct, but I hope you''ve got the main idea. So, my problem is: when rendering adjacent n-patches tesslated with different number of segments it''s most likely to have noticeable seams between them, but I really have no idea how to avoid these seams. May be there is a better solution than mine. Have you got any ideas? Thank you for any suggestions and ideas!

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!