glGetMaterial

return material parameters

Signature

glGetMaterial( )->
glGetMaterialfv( GLenum ( face ) , GLenum ( pname ) , GLfloat * ( params ) )-> void
glGetMaterialfv( face , pname , params )
glGetMaterialiv( GLenum ( face ) , GLenum ( pname ) , GLint * ( params ) )-> void
glGetMaterialiv( face , pname , params )

Parameters

VariablesDescription
face
Specifies which of the two materials is being queried. GL_FRONT or GL_BACK are accepted, representing the front and back materials, respectively.
pname
Specifies the material parameter to return. GL_AMBIENT , GL_DIFFUSE , GL_SPECULAR , GL_EMISSION , GL_SHININESS , and GL_COLOR_INDEXES are accepted.
params
Returns the requested data.

Sample Code References

The following code samples have been found which appear to reference the functions described here. Take care that the code may be old, broken or not even use PyOpenGL.

glGetMaterialfv
OpenGLContext tests/glgetmaterial.py Lines: 14