Specular with Textures and Bump Mapping

First just to take a shot in the dark, if your normal map is showing but the lights aren’t interacting with it, are you sure you have applied it as the normal map and not as the texture map?



Vert and frag files are shader programs written in GLSL (OpenGL Shader Language).

They allow you program the graphics card, in a way, allowing you to create your own effects. Shader programming is quite a field in itself, and there’s plenty of material out ther on it - just google GLSL Shader.

This link looks good, haven’t read it though. http://www.lighthouse3d.com/opengl/glsl/



You should not need to change the shader programs t get bump mapping working. You will need to change them if you want to add specular mapping to the bump mapping. I think that’s a fairly simple one, though.

definitely something i'll try. I'll take another go at it soon because my code just got a bit messy. But at least now I know more about how this all works.



I'm sure I setup the normal map right… texture.setTexture(normalMap,1); with the texture being ,0 and the specular being ,2



i thought it might have been the vert/frag code because when i played with them, i either got light interacting with the model with no texture, or texture with bumpmapping with no interaction with the light. It got shiney in spots when i moved around it but no indication as to which light (if any) that affected it. I'll post again if my next attempts fail. I have to move on to other milestones first.

You might need to tweak your materialstate, especially the specular and shininess have a big impact on how it will look.



Hellmaster