Hi Folks,
A quick one I hope. I want to generate texture co-ords in a vertex shader prog by taken the two smallest of the three vertex components (for simple spherical mapping)
if v.x > v.y
if v.x > v.z
u = v.y
v = v.z
else
u = v.x
v = v.y
end if
else
if v.y > v.z
u = x
v = z
else
u = x
v = y
end if
end if
How simply can this be translated into Vertex Shader code ?
ta ta
Rob J.




