Hi, I have some old assembly code that I'm trying to convert back into HLSL
SubProgram "d3d9 " {
Bind "vertex" Vertex
Bind "color" Color
Matrix 0 [glstate_matrix_mvp]
Vector 4 [_Color]
"vs_2_0
def c5, 1.00000000, 0.50000000, 1.50000000, 0.00000000
dcl_position0 v0
dcl_color0 v1
add r0.x, -v1.w, c5
mul r0, r0.x, c4
min r1.x, r0, r0.z
mul r1.x, r1, c5.y
add r2.x, -r1, c5.z
add r0, r0, v1
slt r1.x, r2, r0
max r1.x, -r1, r1
slt r2.y, c5.w, r1.x
rcp r1.x, r0 …