defb - vs
Defines a Boolean constant value, which should be loaded anytime a shader is set to a device.
Syntax
defb dest, booleanValue |
---|
where
- dst is the destination register.
- booleanValue is a boolean value, either True or False.
Remarks
Vertex shader versions | 1_1 | 2_0 | 2_x | 2_sw | 3_0 | 3_sw |
---|---|---|---|---|---|---|
defb | x | x | x | x | x |
The defb - vs instruction defines a boolean shader constant whose value is loaded anytime a shader is set to a device. These are called immediate constants. Immediate constants take precedence over constants set by the API method SetVertexShaderConstantB.
There are two ways to set a boolean constant in a shader.
- Use defb - vs to define the constant directly inside a shader.
- Use the API methods to set a constant.
- Use SetVertexShaderConstantB to set a Boolean constant.
Related topics