NAME

cgGetNumDependentStateAssignmentParameters - returns the number of effect parameters a state assignment depends on.

SYNOPSIS

  #include <Cg/cg.h>

  int cgGetNumDependentStateAssignmentParameters(CGstateassignment sa);

PARAMETERS

sa

Specifies the state assignment handle.

DESCRIPTION

State assignments in CgFX passes may include references to one or more effect parameters on the right hand side of the state assignment that are used for computing the state assignment's value. cgGetNumDependentStateAssignmentParameters returns the total number of such parameters. the "cgGetDependentStateAssignmentParameter" document can then be used to iterate over the parameters individually.

This information can be useful for applications that wish to cache the values of state assignments for customized state maangement so that they can determine which state assignments may change as the result of changing a parameter's value.

ERRORS

CG_INVALID_STATE_ASSIGNMENT_HANDLE_ERROR is generated if sa does not refer to a valid state assignment.

SEE ALSO

the "cgGetDependentStateAssignmentParameter" document, the "cgGetFirstStateAssignment" document, the "cgGetNamedStateAssignment" document, the "cgGetNumDependentAnnotationParameters" document