Textures unaffected by object lighting

I am having trouble with my textures being seemingly unaffected by the scene lighting. I have looked at another example program using matierials and lighting where it seems to light correctly. I have compared my program to this but cannot see any real difference except perhaps with the sequence of certain commands getting called. I have a scene with different textures and materials which get applied during the drawing process. I wonder if the problem is something to do with sequencing.

Any ideas?

copy/paste the code that works into the program that doesn’t work

then start tweaking it until it looks like the code that does’t work… along the way u’ll find the bug

What texture environment do you use? This often happens when evnironment that ignores previous color (e.g. GL_REPLACE) is used instead of the GL_MODULATE.

Sorry. It looks like I managed to get this working now in the mean time. I must admit though that lighting can be a pain and things don’t neccecarily behave as I might have predicted. I will have to put my OpenGL work on hold for a bit as I have other pressing coursework.