NAME

cgGetProgramContext - get a programs parent context

SYNOPSIS

  #include <Cg/cg.h>

  CGcontext cgGetProgramContext( CGprogram prog );

PARAMETERS

prog

Specifies the program.

DESCRIPTION

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

RETURN VALUES

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

ERRORS

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

SEE ALSO

cgCreateProgram, and cgCreateContext