NAME

cgGetProgramContext - get a programs parent context

SYNOPSIS

  #include <Cg/cg.h>

  CGcontext cgGetProgramContext( CGprogram program );

PARAMETERS

program

The program.

RETURN VALUES

Returns a CGcontext handle to the parent context. In the event of an error NULL is returned.

DESCRIPTION

cgGetProgramContext allows the application to retrieve a handle to the context a given program belongs to.

EXAMPLES

to-be-written

ERRORS

CG_INVALID_PROGRAM_HANDLE_ERROR is generated if program does not refer to a valid program.

HISTORY

cgGetProgramContext was introduced in Cg 1.1.

SEE ALSO

cgCreateProgram, cgCreateContext