I have been working on a terrain and have had to come to a complete stop. I am programming in C++, DirectX9 and HLSL to create the terrain but I am also using height maps that are BMP format. I am loading the information in from the height map in both the C++ side as well as the shader side. On the C++ side, I am using D3DXCreateTextureFromFile and surfaces (D3DXSaveSurfaceToFile) to load the information, whereas on the shader side, I am using tex2Dlod to load my information for the terrain vertices. These two are getting different values from the height map. Upon further research, I found out that the tex2Dlod function utilizes mip maps (still don't understand those fully) to load the information.
Would anyone know a way on how to get the two numbers to match up? If you need more information (the numbers, pictures or whatever) just let me know!
Thanks!