OpenGL - GL_FRONT versus GL_FRONT_AND_BACK
Posted
by Drew Noakes
on Stack Overflow
See other posts from Stack Overflow
or by Drew Noakes
Published on 2010-06-12T04:24:33Z
Indexed on
2010/06/12
4:32 UTC
Read the original article
Hit count: 215
opengl
I'm tinkering with an open source project that uses OpenGL for rendering in 3D. In the construction of the materials I see code like this:
// set ambient material reflectance
glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, mAmbient);
In other examples, this is used:
glMaterialfv(GL_FRONT, GL_AMBIENT, mAmbient);
So my question is, what is the difference here? Under what circumstances would it look different and, if my volume is enclosed with all normals pointing outwards, is there any performance difference?
© Stack Overflow or respective owner