-> Click here to learn how to get live help <-
NAMEglPolygonMode - select a polygon rasterization mode
C SPECIFICATIONvoid f3glPolygonModefP( GLenum fIfacefP,
f2facefP Specifies the polygons that f2modefP applies to. Must be %f3GL_FRONTfP for front-facing polygons, %f3GL_BACKfP for back-facing polygons, or %f3GL_FRONT_AND_BACKfP for front- and back-facing polygons.
DESCRIPTION%f3glPolygonModefP controls the interpretation of polygons for rasterization. f2facefP describes which polygons f2modefP applies to: front-facing polygons (%f3GL_FRONTfP), back-facing polygons (%f3GL_BACKfP), or both (%f3GL_FRONT_AND_BACKfP). The polygon mode affects only the final rasterization of polygons. In particular, a polygon's vertices are lit and the polygon is clipped and possibly culled before these modes are applied. Three modes are defined and can be specified in f2modefP:
EXAMPLESTo draw a surface with filled back-facing polygons and outlined front-facing polygons, call glPolygonMode(%f3GL_FRONTfP, %f3GL_LINEfP);
NOTESVertices are marked as boundary or nonboundary with an edge flag. Edge flags are generated internally by the GL when it decomposes polygons; they can be set explicitly using %f3glEdgeFlagfP.
ERRORS%f3GL_INVALID_ENUMfP is generated if either f2facefP or f2modefP is not an accepted value. %f3GL_INVALID_OPERATIONfP is generated if %f3glPolygonModefP is executed between the execution of %f3glBeginfP and the corresponding execution of %f3glEndfP.
ASSOCIATED GETS%f3glGetfP with argument %f3GL_POLYGON_MODEfP
SEE ALSO%f3glBegin(3G)fP, %f3glEdgeFlag(3G)fP, %f3glLineStipple(3G)fP, %f3glLineWidth(3G)fP, %f3glPointSize(3G)fP, %f3glPolygonStipple(3G)fP