Skip to main content
GameDev.net gamedev.net
🔒 Locked

ground height

Started by vampman Jan 5, 2001 at 1:18 PM 0 replies 450+ views
Original Post
vampman
vampman
How can I get the ground height from XTerminate?
tcs
tcs
That should be pretty easy. One method is to just keep the heighmap in memory. Make it a member of the CLandscape and don''t throw it away. Then you can interpolate your position through the heightmap image. See the scale heightmap function or my glExplorer demo to see how it''s done. Another option is to use the build in collision functions. CheckIntersection() doesn''t give you the intersection point with the terrain, but the math is already build in CTriangle. All you have to do is write a CheckIntersection() function that returns the height or the whole point.

Tim

--------------------------
glvelocity.gamedev.net
www.gamedev.net/hosted/glvelocity
Tim--------------------------glvelocity.gamedev.netwww.gamedev.net/hosted/glvelocity

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.