best way to visualize a heightfield in OpenGL


#1

hello,

what would be the best way to draw a heightfield with OpenGl?
normally you have the data in a two-dimensional array.

i tried it with GL_QUADS and GL_TRIANGLE_STRIPS but the outcome is a little strange as you can see in this screenshot:

the problem is that there is a certain orientation of the polygons which shouldnt be there.

thanks!


#2

It looks to me like your tesselation is not fine enough. Also, when using quads, make sure they’re planar.


#3

Looks to me like the field function …

Is not dynamic enough over that range and also like the other respondent said … not enough resolution.


#4

no
meanwhile i tried different approches.
now im erndering it linewise with single triangels. this works fine and i get a smooth heightfield.

thanks anyways.


#5

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.