Dynamic Normalmaps?

Posted By: GhostDude

Dynamic Normalmaps? - 12/09/04 11:58

Newbie question time...

Is it possible to define a bmap, draw to it during the game using pixel_to_bmap, convert it to a normalmap, and then use it in a dot3 bump mapping material effect? I have tried doing this, but the changes to the bmap dont seem to have any effect. Im really interested in getting this to work, because you could then simulate carving out a surface, or something like that. However, I really dont know a lot about shaders, and so I am really hoping that this can be done with material effects and not pixel or vertex shaders (I'm not sure what my graphics card supports.)

Is it possible to convert a bmap to a normalmap, and then draw to it? I tried this, but i didnt get the results i wanted. It seems like that might be the answer to my problem though, if it is even possible.

Also, since im already on the subject, what exactly is the difference between "material effects" and shaders? I understand the basic idea behind shaders interrupting the graphics pipeline (i hope thats right ) but i dont see how that is different from a material effect.
Posted By: Matt_Aufderheide

Re: Dynamic Normalmaps? - 12/09/04 16:10

Quote:

Is it possible to define a bmap, draw to it during the game using pixel_to_bmap, convert it to a normalmap, and then use it in a dot3 bump mapping material effect?



It should be. But i imagine it would be very slooow.

Quote:

Is it possible to convert a bmap to a normalmap, and then draw to it?



no it's not. At least, you cant draw to it and preserve the normals data.

Quote:

what exactly is the difference between "material effects" and shaders?



material effects can use either the fixed-function pipeline or vertex and pixel shaders. Shaders are just the programmable part of the material effect.. you can have a material without any shaders, but you can't have shaders without a material.
Posted By: M3PHiSTOPH3L3S

Re: Dynamic Normalmaps? - 12/12/04 08:28

I have seen source code in Render Monkey for a shader that generates DOT3 maps from heightmaps if I remember correctly. I'm not sure how much this helps you, but I'm pretty sure with some work this could accomplish what you want.

M3PHiSTO
© 2024 lite-C Forums