A few quick questions if anyone can answer them. My main goal is to create an arbitrarily shaped surface and color it. The color of it's pixels is given by it's displacement and is very dynamic. The shape of this surface is also very dynamic.
What I am doing right now is a very brtue force tatic of going through each bit of surface data and drawing the surface triangle by triangle, specifying the color at each vertex, and specifying a normal. All in all it looks great but is running a bit on the slow side as drawing thousands of triangles (or at least going through the nested for loops) seems to be hogging resources.
I came across the idea of displacement mapping and figured that maybe specifying a texture would be easier/faster since maybe the hardware will be doing a lot of the computation. Are there any tutorials on how to displcement map? That way I can draw a simple plane (2 triangles) and use a texture instead of drawing thousands of triangles? Also, would that even be feasible? Since I have to color the surface anyway and the color is very dynamic, I may have to go through the nested for loops for the color anyway! I could make a texture for the colors too, but that would require a few loops to get the color data and then how do I make sure the color would be on the surface (the surface would be a texture no? So textures on a texture??!?!?) Any ideas? I would love to have this run at a reasonable speed without downsampling. Thanks!
P.S. If there are good downsampling techniques or good estimators, I would like to see them anyway.