cgSetBoolStateAssignment
Keywords: cgSetBoolStateAssignment, NVIDIA, NVIDIA Cg Toolkit, Cg Toolkit, Shader, Shader Programming, GPU Shader Programming, GPU Program

> ## Name

> cgSetBoolStateAssignment - set the value of a bool state assignment

> ## Synopsis

>     #include <Cg/cg.h>

>     CGbool cgSetBoolStateAssignment( CGstateassignment sa,
>                                      CGbool value );

> ## Parameters

> sa
>   A handle to a state assignment of type CG_BOOL.
> value
>   The value to which sa will be set.

> ## Return Values

> Returns CG_TRUE if it succeeds in setting the state assignment.

> Returns CG_FALSE otherwise.

> ## Description

> cgSetBoolStateAssignment sets the value of a state assignment of bool type.

> ## Examples

> to-be-written

> ## Errors

> CG_INVALID_STATE_ASSIGNMENT_HANDLE_ERROR is generated if sa is not a valid state assignment.

> CG_STATE_ASSIGNMENT_TYPE_MISMATCH_ERROR is generated if sa is not a state assignment of a bool type.

> CG_ARRAY_SIZE_MISMATCH_ERROR is generated if sa is an array and not a scalar.

> ## History

> cgSetBoolStateAssignment was introduced in Cg 1.5.

> ## See Also

> cgGetBoolStateAssignmentValues, cgSetBoolArrayStateAssignment, cgSetFloatArrayStateAssignment, cgSetFloatStateAssignment, cgSetIntArrayStateAssignment, cgSetIntStateAssignment, cgSetProgramStateAssignment, cgSetSamplerStateAssignment, cgSetStringStateAssignment, cgSetTextureStateAssignment