Name
cgIsContext - determine if a context handle references a valid context
Synopsis
#include <Cg/cg.h>
CGbool cgIsContext( CGcontext context );
Parameters
- context
-
The context handle to check.
Return Values
Returns CG_TRUE if context references a valid context.
Returns CG_FALSE otherwise.
Description
cgIsContext returns CG_TRUE if context references a valid
context, CG_FALSE otherwise.
Examples
CGcontext context = NULL;
cgIsContext(context); /* returns CG_FALSE */
context = cgCreateContext();
cgIsContext(context); /* returns CG_TRUE if create succeeded */
cgDestroyContext(context);
cgIsContext(context); /* returns CG_FALSE */
Errors
None.
History
cgIsContext was introduced in Cg 1.1.
See Also
cgCreateContext,
cgDestroyContext
|