Dot3 Bumpmapping

Does anyone know of any OpenGL demo’s that showoff the EXT_texture_env_dot3 extension for bumpmapping/per-pixel lighting effects?

I found one on ATI’s site but it uses 3D textures (for lightmaps) so I can’t run it on my GeForce2.

I’d also like a link to some tutorials/explanations of this extension (other than the ext spec).


Jason A.
DelphiGL( )

It shouldn’t be very hard to modify that demo to take out the distance attenuation term (which uses a 3D texture).


Well you also use a third texture unit throughout the program so on a GeForce you’d have to modify that and do it using multiple passes over the geometry.

Unless there is some other way to do it?

I am currently reading over the source code to get an understanding of whats going on, I will try and see if I can get it too run on a GeForce.

Isn’t the idea of this extension that you send down a normal map (with x,y,z delta substituted for r,g,b) as one texture, and send down the diffuse light direction as the texture environment color? That way, you get “per-pixel” lighting (really per-texel, but who’s counting? :slight_smile:

Apart from preparing the normal map texture, it seems pretty straightforward.

jwatte, that’s the way I saw it when I saw the texture that made the normal map. Pretty nifty way of implimenting per-pixel lighting.

Use register combiners…gives you more flexibility, but only used on NVidia cards.