NAME

cgSetAutoCompile - sets the auto-compile mode for a context

SYNOPSIS

  #include <Cg/cg.h>

  void cgSetAutoCompile(CGcontext ctx, CGenum flag);

PARAMETERS

ctx

Specifies the context.

flag

The auto-compile mode to set the ctx to. Must be one of the following :

  • CG_COMPILE_MANUAL
  • CG_COMPILE_IMMEDIATE
  • CG_COMPILE_LAZY

DESCRIPTION

cgSetAutoCompile sets the auto compile mode for a given context. By default, programs are immediately recompiled when they enter an uncompiled state. This may happen for a variety of reasons including :

flag may be one of the following three enumerants :

ERRORS

CG_INVALID_CONTEXT_HANDLE_ERROR is generated if ctx is invalid.

CG_INVALID_ENUMERANT_ERROR is generated if flag is invalid.

SEE ALSO

the "cgCompileProgram" document, and the "cgIsProgramCompiled" document