PDA

View Full Version : glMaterial*() and Texture Mapping don't work together



mekron
07-10-2004, 09:00 AM
Hallo,

when i use the glMaterial*()-Function und the OpenGL Texture Mapping in the same programm the screen keeps black after starting the programm.
When i use instead of glMaterial*() something like this it works:

glEnable(GL_COLOR_MATERIAL);
.
.
glColor3f(....);

Is it impossible to use glMaterial*() and Texture Mapping together?

Regards
mekron

ZbuffeR
07-10-2004, 09:50 AM
Maybe you want to adjust glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_xxx); according to your needs.

Be sure not to specify a black material. Try to disable/enable lighting and see if there are differences.

mekron
07-11-2004, 12:10 AM
i have set glTexEnv*() with new values. Now it works fine!
...Thank you ...mekron