Name
cgGetStateLatestProfile - gets a state's designated latest profile
Synopsis
#include <Cg/cg.h>
CGprofile cgGetStateLatestProfile( CGstate state );
Parameters
- state
-
The state handle.
Return Values
Returns the designated latest profile if state is of type CG_PROGRAM_TYPE.
Returns CG_PROFILE_UNKNOWN otherwise.
Description
cgGetStateLatestProfile gets the specified state's designated latest
profile for states of type CG_PROGRAM_TYPE.
This profile is used to compile the program for a state assignment
for the state where the profile in the compile statement is the
identifier latest.
Examples
Get the latest profile for fragment programs:
CGstate state = cgGetNamedState(context, "FragmentProgram");
CGprofile profile = cgGetStateLatestProfile(state);
Errors
CG_INVALID_STATE_HANDLE_ERROR is generated if state is not a valid state.
History
cgGetStateLatestProfile was introduced in Cg 2.2.
See Also
cgGetNamedState,
cgSetStateLatestProfile
|