Parameters (Direct3D 9)

Parameters are effect variables.


usage type ID [: semantic] [<annotation(s)>] [= expression];

Parameters can be read from and written to by the application with ID3DXEffect or ID3DXEffectCompiler.

Parameters can be referenced in functions and in techniques (specifically, in the right side of state assignments).

Item Description
Scope of the parameter. See Usages and Literals (Direct3D 9).
Any valid Reference for HLSL type.
A unique name.
A tag following identifier rules that typically indicates the usage of the parameter. Must be a particular type.
Zero or more pieces of user-specific information. May be any type. See Add Information to Effect Parameters with Annotations.
Initializes the parameter's value. See Expressions (Direct3D 9).


Parameters can be initialized to any valid Reference for HLSL expression that reduces to a literal value.

Parameter values are not changed by the execution of state assignment or function calls.

Effect Format