Position Register
Microsoft DirectX 9.0 SDK Update (October 2004)

Position Register


This vertex shader output register contains per-vertex position data.

Syntax

Position Register 

Remarks

Remarks
Vertex shader versions1_12_02_sw2_x3_03_sw
Position Registerxxxxxx

A register consists of properties that determine how each register behaves.

PropertyDescription
NameoPos
Count1 vector
I/O permissionsWrite-only.

The value is the position in homogeneous clipping space. This value must be written by the vertex shader.

Example

dcl_position v0

def c40, 0.0f,0.0f,0.0f,0.0f;
// transform into projection space
m4x4 r0,v0,c8
max r0.z,c40.z,r0.z //clamp to 0
max r0.w,c12.x,r0.w //clamp to near clip plane
mov oPos,r0   



© 2004 Microsoft Corporation. All rights reserved.
Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center.