[ Previous | Next | Contents | Glossary | Home | Search ]
OpenGL 1.1 for AIX: Reference Manual

glCullFace Subroutine

Purpose

Specifies whether frontfacing or backfacing facets may be culled.

Library

OpenGL C bindings library: libGL.a

C Syntax

void glCullFace(GLenum mode)

Parameters

mode Specifies whether frontfacint or backfacing facets are candidates for culling. Symbolic constants GL_FRONT, GL_BACK, and GL_FRONT_AND_BACK are accepted. The initial value is GL_BACK.

Description

The glCullFace subroutine specifies whether frontfacing or backfacing facets are culled (as specified by the mode parameter) when facet culling is enabled. Facet culling is enabled and disabled using the glEnable and glDisable subroutines with the argument GL_CULL_FACE. Facets include triangles, quadrilaterals, polygons, and rectangles.

The glFrontFace subroutine specifies which of the clockwise and counterclockwise facets are frontfacing and backfacing.

Notes

If mode is GL_FRONT_AND_BACK, no facets are drawn, but other primitives such as points and lines are drawn.

Errors

GL_INVALID_ENUM is generated if mode is not an accepted value.

GL_INVALID_OPERATION is generated if glCullFace is executed between the execution of glBegin and the corresponding execution of glEnd.

Associated Gets

glIsEnabled with argument GL_CULL_FACE

glGet with argument GL_CULL_FACE_MODE

Files

/usr/include/GL/gl.h Contains C language constants, variable type definitions, and ANSI function prototypes for OpenGL.

Related Information

The glEnable or glDisable subroutine, glFrontFace subroutine.

OpenGL Overview.


[ Previous | Next | Contents | Glossary | Home | Search ]