float htTl = mHeightMap->Val(x1, y1);float htTr = mHeightMap->Val(x2, y1);float htBl = mHeightMap->Val(x1, y2);float htBr = mHeightMap->Val(x2, y2);
and this is my vertex structure:
struct TERRAINVERTEX // Define the terrain vertex structure{ FLOAT x, y, z; // Position (x-, y-, and z-axis) DWORD m_dwColor; // Vertex color FLOAT u, v; // Vertex texture coordinates};
How would I use x1, y1, x2, and y2 in my array of "TERRAINVERTEX"? It''s stored in the terrain class as "TERRAINVERTEX *m_pVertex;". If I knew how the "Val" function was meant to work, the way Aph3x showed me, I should be able to get it working in my own code.
If I cannot get this possible solution to work, I will go with your suggestion, hplus0603. =)
Thanks,
Matt U.