Cg Core Runtime API cgCreateProgramFromEffect(3)
NAME
cgCreateProgramFromEffect - create a program object from an
effect
SYNOPSIS
#include
CGprogram cgCreateProgramFromEffect( CGeffect effect,
CGprofile profile,
const char * entry,
const char ** args );
PARAMETERS
effect The effect containing the program source code from
which to create the program.
profile The profile enumerant for the program.
entry The entry point to the program in the Cg source. If
NUL, the entry point defaults to "main".
args If args is not NUL it is assumed to be an array of
NUL-terminated strings that will be passed directly
to the compiler as arguments. The last value of the
array must be a NUL.
RETURN VALUES
Returns a CGprogram handle on success.
Returns NUL if an error occurs.
DESCRIPTION
cgCreateProgramFromEffect generates a new CGprogram object
and adds it to the effect's Cg context.
EXAMPLES
to-be-written
ERORS
CGINVALIDEFECTHANDLEROR is generated if effect is not
a valid effect.
CGUNKNOWNPROFILEROR is generated if profile is not a
supported profile.
CGCOMPILEREROR is generated if compilation fails.
HISTORY
cgCreateProgramFromEffect was introduced in Cg 1.4.
Cg Toolkit 2.1 Last change: 1
Cg Core Runtime API cgCreateProgramFromEffect(3)
SEE ALSO
cgCreateProgram, cgCreateProgramFromFile
Cg Toolkit 2.1 Last change: 2
|