HM_SIZE_X and HM_SIZE_Y are both 6
OpenGL API Specifications
Documents and Learning ResourcesSupport Libraries and FrameworksFunction Libraries and GeneratorsThis list contains some basic resources for getting started with, and developing for, OpenGL 3.0 and onwards. Contact your forum moderator if you want to contribute to the list or have any comments.Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
Posted 18 February 2017 - 09:53 AM
Posted 18 February 2017 - 02:44 PM
You know where you vertices are.
You know the size of a quad.
You know where the camera is.
From there you can determine which quad the camera is in. ( camera x - mesh x ) / quad size = quad x. similar for z.
and from there you can determine which triangle of the quad the camera is in.
from that you can lerp down the two sides of the triangle, then lerp between those results to get the height of the triangle at the camera's location.
Norm Barrows
Rockland Software Productions
"Building PC games since 1989"
PLAY CAVEMAN NOW!
http://rocklandsoftware.net/beta.php
Posted 20 February 2017 - 11:45 AM
You know where you vertices are.
You know the size of a quad.
You know where the camera is.
From there you can determine which quad the camera is in. ( camera x - mesh x ) / quad size = quad x. similar for z.
and from there you can determine which triangle of the quad the camera is in.
from that you can lerp down the two sides of the triangle, then lerp between those results to get the height of the triangle at the camera's location.
How would I determine which triangle of the quad the camera is in?
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
GameDev.net™, the GameDev.net logo, and GDNet™ are trademarks of GameDev.net, LLC.