Instructions
Direct3D 8 - Vertex Shader - Instructions (Microsoft)
Last edited 2026-01-27
This section contains reference information for the vertex shader vs.1.x instructions.
There are several types of vertex shader instructions, as shown in the table.
Columns to the right mean the following:
- Instruction slots - Number of instruction slots used by each instruction.
- Setup - Non-arithmetic instructions. Every shader must have a version instruction and it must be the first instruction.
- Arithmetic - These instructions provide the mathematical operations in a shader.
The meaning of colors in the Type column:
|
Color |
Description |
|
Green |
The instruction works in Fusion. |
|
Yellow |
The instruction has not been confirmed to work in Fusion. |
|
Red |
The instruction does not work in Fusion. |
Vertex instructions
|
Type |
Instruction |
Description |
Instruction slots |
Setup |
Arithmetic |
vs.1.0 |
vs.1.1 |
Note |
|
asm |
add |
Add two vectors |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
dcl_usage |
Declare input vertex registers |
0 |
Yes |
|
Unknown |
Yes |
TODO |
|
asm |
def |
Define constants |
0 |
Yes |
|
Unknown |
Yes |
TODO |
|
asm |
dp3 |
Three-component dot product |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
dp4 |
Four-component dot product |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
dst |
Calculate the distance vector |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
exp |
Full precision 2x |
10 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
expp |
Partial precision 2x |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
frc |
Fractional component |
3 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
lit |
Partial lighting calculation |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
log |
Full precision log₂(x) |
10 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
logp |
Partial precision log₂(x) |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
m3x2 |
3x2 multiply |
2 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
m3x3 |
3x3 multiply |
3 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
m3x4 |
3x4 multiply |
4 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
m4x3 |
4x3 multiply |
3 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
m4x4 |
4x4 multiply |
4 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
mad |
Multiply and add |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
max |
Maximum |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
min |
Minimum |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
mov |
Move |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
mul |
Multiply |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
nop |
No operation |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
rcp |
Reciprocal square root |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
sge |
Greater than or equal compare |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
sit |
Less than compare |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
sub |
Subtract |
1 |
|
Yes |
Unknown |
Yes |
TODO |
|
asm |
vs |
Declare vertex shader version |
0 |
Yes |
|
Unknown |
Yes |
TODO |
Created with the Personal Edition of HelpNDoc: Maximize Your Productivity with a Help Authoring Tool