Vertex Shader Differences
Instruction Slots
Each version supports a differing number of maximum instruction slots.
Version |
Maximum number of instruction slots |
vs_1_1 |
128 |
vs_2_0 |
256 |
vs_2_x |
256 |
vs_3_0 |
512 minimum, and up to the number of slots in D3DCAPS9.MaxVertexShader30InstructionSlots. See D3DCAPS9. |
For information about the limitations of software shaders, see Software Shaders.
Flow Control Nesting Limits
vs_1_1 Features
New instructions:
See Instructions - vs_1_1.
New registers:
See Registers - vs_1_1.
vs_2_0 Features
New features:
- Static flow control
- All four components of the Address Register (a0) are available.
New instructions:
- Setup instructions - defb - vs, defi - vs
- Arithmetic instructions - abs - vs, crs - vs, lrp - vs, mova - vs, nrm - vs, pow - vs, sgn - vs, sincos - vs
- Static flow control instructions - call - vs, callnz bool - vs, else - vs, endif - vs, endloop - vs, endrep - vs, if bool - vs, label - vs, loop - vs, rep - vs, ret - vs
New registers:
vs_2_x Features
New features (D3DCAPS9.VS20Caps):
- Dynamic flow control
- Nesting for dynamic and static flow control instructions
- Number of Temporary Registers (r#) increased
- Predication
New Instructions:
New registers:
vs_3_0 Features
New features :
- Texture lookup
- Indexable Output Registers (o#)
- Number of Temporary Registers (r#) increased to 32
New instructions:
New registers: