Name
cgGLEnableTextureParameter - enables the texture unit associated with a
texture parameter
Synopsis
#include <Cg/cgGL.h>
void cgGLEnableTextureParameter( CGparameter param );
Parameters
- param
-
The texture parameter which will be enabled.
Return Values
None.
Description
cgGLEnableTextureParameter binds and enables the texture object associated
with param. It must be called after cgGLSetTextureParameter
is called but before the geometry is drawn.
cgGLDisableTextureParameter should be called once
all of the geometry is drawn to avoid applying the texture to the wrong geometry
and shaders.
Examples
to-be-written
Errors
CG_INVALID_PROFILE_ERROR is generated if param's profile is not
a supported OpenGL profile. In particular, if param is not a parameter
handle retrieved from a CGprogram but was instead retrieved from a
CGeffect or is a shared parameter created at runtime, this error will be
generated since those parameters do not have a profile associated with them.
CG_INVALID_PARAM_HANDLE_ERROR is generated if param is not a valid parameter.
CG_INVALID_PARAMETER_ERROR is generated if param is not a texture
parameter or if the enable operation fails for any other reason.
History
cgGLEnableTextureParameter was introduced in Cg 1.1.
See Also
cgGLDisableTextureParameter,
cgGLSetTextureParameter
|