ps_2_0
// pixel shader to prepare object intersection results to receive shadows
// inputs:
// tex0 - shadow test rays origins buffer (intersection positions)
// c0 - point light position
// outputs shadow test ray direction
//         w component is light origin distance
dcl t0
dcl_2d s0
def c8,0.01,0,0,0
texld r0,t0,s0
sub r0,c0,r0
nrm r1,r0
dp3 r0.w,r0,r0
rsq r2.x,r0.w
rcp r0.w,r2.x
mul r1.w,r0.w,c8.x
mov oC0,r1
