JanHH
04-23-2003, 05:17 PM
Hello,
another stupid question from me: When using material properties (ambient, diffuse, specular) and specifiying them separatly with glMaterial, the performance of my app is extremely slow (rendering a terrain with some 100.000 triangles). However, when enabling GL_COLOR_MATERIAL and using glColor instead of glMaterial, it speeds up dramatically.. running absolutely smooth and fast, compared to nearly "standbilder" with glMaterial. It's obvious that it gets faster because of less calls to set the color, but that does not explain this extremely big difference in performance. I guess that other things that happen inside OpenGL are also different with GL_COLOR_MATERIAL enabled? A whole different/simpler lightnig model without specular highlights?
Regards
Jan
another stupid question from me: When using material properties (ambient, diffuse, specular) and specifiying them separatly with glMaterial, the performance of my app is extremely slow (rendering a terrain with some 100.000 triangles). However, when enabling GL_COLOR_MATERIAL and using glColor instead of glMaterial, it speeds up dramatically.. running absolutely smooth and fast, compared to nearly "standbilder" with glMaterial. It's obvious that it gets faster because of less calls to set the color, but that does not explain this extremely big difference in performance. I guess that other things that happen inside OpenGL are also different with GL_COLOR_MATERIAL enabled? A whole different/simpler lightnig model without specular highlights?
Regards
Jan