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

> ## Name

> cgSetParameter2i - set the value of scalar and vector parameters

> ## Synopsis

>     #include <Cg/cg.h>

>     void cgSetParameter2i( CGparameter param,
>                            int x,
>                            int y );

> ## Parameters

> param
>   The parameter that will be set.
> x, y
>   The values used to set param.

> ## Return Values

> None.

> ## Description

> cgSetParameter2i sets the value of a given scalar or vector parameter.

> If more values are passed in than param requires, the extra values will be ignored.

> Once cgSetParameter2i has been used to set a parameter, the values may be retrieved from the parameter using the CG_CURRENT enumerant with cgGetParameterValues.

> If an API-dependant layer of the Cg runtime (e.g. cgGL) is used, these entry points may end up making API (e.g. OpenGL) calls.

> ## Examples

> to-be-written

> ## Errors

> CG_INVALID_PARAM_HANDLE_ERROR is generated if param is not a valid parameter.

> CG_INVALID_PARAMETER_ERROR is generated if param is a varying input to a fragment program.

> ## History

> cgSetParameter2i was introduced in Cg 1.4.

> ## See Also

> cgGetParameterValue, cgGetParameterValues