//
// Generated by Microsoft (R) D3D Shader Disassembler
//
//   using 3Dmigoto v1.2.7 on Thu Nov 12 18:21:54 2015
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float   xy  
// COLOR                    1   x           1     NONE    uint   x   
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Target                0   xyzw        0   TARGET   float   xyzw
// SV_Target                1   xyzw        1   TARGET   float   xyzw
// SV_Target                2   xyzw        2   TARGET   float   xyzw
// SV_Target                3   xyzw        3   TARGET   float   xyzw
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer cb12[31], immediateIndexed
dcl_constantbuffer cb2[7], immediateIndexed
dcl_sampler s1, mode_default
dcl_sampler s7, mode_default
dcl_sampler s9, mode_default
dcl_sampler s11, mode_default
dcl_sampler s12, mode_default
dcl_resource_texture2d (float,float,float,float) t1
dcl_resource_texture2d (float,float,float,float) t7
dcl_resource_structured t8, 224 
dcl_resource_texture2d (float,float,float,float) t9
dcl_resource_texture2d (float,float,float,float) t11
dcl_resource_texture2d (float,float,float,float) t12
dcl_resource_texture2d (float,float,float,float) t125
dcl_input_ps_siv linear noperspective v0.xy, position
dcl_input_ps constant v1.x
dcl_output o0.xyzw
dcl_output o1.xyzw
dcl_output o2.xyzw
dcl_output o3.xyzw
//dcl_temps 13
dcl_temps 28

ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r0.xyzw, v1.x, l(0), t8.xyzw
ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r1.xyzw, v1.x, l(16), t8.xyzw
ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r2.xyzw, v1.x, l(32), t8.xyzw
ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r3.xyz, v1.x, l(144), t8.xyzx
ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r4.xyz, v1.x, l(160), t8.xyzx
ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r5.xyzw, v1.x, l(192), t8.xyzw
ld_structured_indexable(structured_buffer, stride=224)(mixed,mixed,mixed,mixed) r3.w, v1.x, l(220), t8.xxxx
mul r6.xy, v0.xyxx, cb2[0].xyxx
sample_l_indexable(texture2d)(float,float,float,float) r4.w, r6.xyxx, t7.yzwx, s7, l(0.000000)
sample_l_indexable(texture2d)(float,float,float,float) r6.zw, r6.xyxx, t1.zwxy, s1, l(0.000000)
mad r6.zw, r6.zzzw, l(0.000000, 0.000000, 4.000000, 4.000000), l(0.000000, 0.000000, -2.000000, -2.000000)
dp2 r7.x, r6.zwzz, r6.zwzz
mad r7.xy, -r7.xxxx, l(0.250000, 0.500000, 0.000000, 0.000000), l(1.000000, 1.000000, 0.000000, 0.000000)
sqrt r7.x, r7.x
mul r8.xy, r6.zwzz, r7.xxxx
mov r8.z, -r7.y
ge r6.z, l(0.010000), r4.w
if_nz r6.z
  mul r7.z, r4.w, l(100.000000)
  mov r9.xyzw, cb12[24].xyzw
  mov r10.xyzw, cb12[25].xyzw
  mov r11.xyzw, cb12[26].xyzw
  mov r12.xyzw, cb12[27].xyzw
else 
  mad r7.z, r4.w, l(1.010000), l(-0.010000)
  mov r9.xyzw, cb12[20].xyzw
  mov r10.xyzw, cb12[21].xyzw
  mov r11.xyzw, cb12[22].xyzw
  mov r12.xyzw, cb12[23].xyzw
endif 
mul r6.x, r6.x, cb2[5].x
mad r6.z, -r6.y, cb2[5].y, l(1.000000)
mad r7.xy, r6.xzxx, l(2.000000, 2.000000, 0.000000, 0.000000), l(-1.000000, -1.000000, 0.000000, 0.000000)
mov r7.w, l(1.000000)
dp4 r6.x, r9.xyzw, r7.xyzw
dp4 r6.y, r10.xyzw, r7.xyzw
dp4 r6.z, r11.xyzw, r7.xyzw
dp4 r4.w, r12.xyzw, r7.xyzw
div r6.xyz, r6.xyzx, r4.wwww

ld_indexable(texture2d)(float,float,float,float) r28.xyzw, l(0, 0, 0, 0), t125.xyzw
add r28.w, r6.z, -r28.y
mul r28.w, r28.w, r28.x
mul r28.w, r28.w, cb12[20].x
add r6.x, r6.x, -r28.w

dp3 r4.w, -r6.xyzx, -r6.xyzx
rsq r4.w, r4.w
mul r7.xyz, r4.wwww, -r6.xyzx
eq r4.w, cb2[6].y, l(-1.000000)
dp3 r7.x, r7.xyzx, r4.xyzx
add r7.x, -r7.x, l(1.000000)
log r7.x, r7.x
mul r7.x, r7.x, cb2[6].y
exp r7.x, r7.x
min r7.x, r7.x, l(1.000000)
add r7.x, r7.x, l(-1.000000)
mad r7.x, cb12[30].x, r7.x, l(1.000000)
movc r4.w, r4.w, l(1.000000), r7.x
mov r6.w, l(1.000000)
dp4 r0.x, r0.xyzw, r6.xyzw
dp4 r0.y, r1.xyzw, r6.xyzw
dp4 r0.z, r2.xyzw, r6.xyzw
add r1.xy, -r5.xyxx, r0.xyxx
lt r1.xy, r1.xyxx, l(0.000000, 0.000000, 0.000000, 0.000000)
or r0.w, r1.y, r1.x
discard_nz r0.w
add r1.xy, -r0.xyxx, r5.zwzz
lt r1.xy, r1.xyxx, l(0.000000, 0.000000, 0.000000, 0.000000)
or r0.w, r1.y, r1.x
discard_nz r0.w
add r0.w, -r0.z, l(1.000000)
lt r0.zw, r0.zzzw, l(0.000000, 0.000000, 0.000000, 0.000000)
discard_nz r0.w
discard_nz r0.z
lod r0.z, r0.xyxx, t9.x, s9
dp3 r0.w, -r2.xyzx, -r2.xyzx
rsq r0.w, r0.w
mul r1.xyz, r0.wwww, -r2.xyzx
deriv_rtx_coarse r2.xyz, r6.zxyz
dp3 r0.w, r2.xyzx, r2.xyzx
rsq r0.w, r0.w
mul r2.xyz, r0.wwww, r2.xyzx
deriv_rty_coarse r5.xyz, r6.yzxy
dp3 r0.w, r5.xyzx, r5.xyzx
rsq r0.w, r0.w
mul r5.xyz, r0.wwww, r5.xyzx
mul r6.xyz, r2.xyzx, r5.xyzx
mad r2.xyz, r2.zxyz, r5.yzxy, -r6.xyzx
dp3 r0.w, r2.xyzx, r2.xyzx
rsq r0.w, r0.w
mul r2.xyz, r0.wwww, r2.xyzx
dp3 r0.w, r2.xyzx, r1.xyzx
add r0.w, r0.w, l(-0.300000)
lt r0.w, r0.w, l(0.000000)
dp3 r1.x, r1.xyzx, r8.xyzx
add r1.x, r1.x, l(-0.300000)
lt r1.y, r1.x, l(0.000000)
and r1.y, r0.w, r1.y
discard_nz r1.y
sample_l_indexable(texture2d)(float,float,float,float) r2.xyzw, r0.xyxx, t9.xyzw, s9, r0.z
sample_l_indexable(texture2d)(float,float,float,float) r1.yz, r0.xyxx, t12.zxyw, s12, r0.z
sample_l_indexable(texture2d)(float,float,float,float) r0.xy, r0.xyxx, t11.xyzw, s11, r0.z
max r0.z, r1.x, l(0.000000)
min r0.z, r0.z, l(0.250000)
movc r0.z, r0.w, r0.z, l(0.250000)
mul r0.z, r2.w, r0.z
mul r0.w, r0.z, l(4.000000)
mad r0.z, r0.z, l(4.000000), l(-0.0156862754)
lt r0.z, r0.z, l(0.000000)
discard_nz r0.z
mul r0.z, r3.w, r0.w
mad r5.xy, r0.xyxx, l(2.000000, 2.000000, 0.000000, 0.000000), l(-1.000000, -1.000000, 0.000000, 0.000000)
dp2 r0.x, r5.xyxx, r5.xyxx
add r0.x, -r0.x, l(1.000000)
max r0.x, r0.x, l(0.000000)
sqrt r5.z, r0.x
mul r0.xyw, r3.xyxz, r4.yzyx
mad r0.xyw, r4.xyxz, r3.yzyx, -r0.xyxw
mul r3.xyz, -r4.yzxy, r0.xywx
mad r3.xyz, r0.wxyw, -r4.zxyz, -r3.xyzx
mov r6.x, r0.y
mov r6.y, r3.x
mov r6.z, r4.x
dp3 r6.x, r5.xyzx, r6.xyzx
mov r7.x, r0.w
mov r7.y, r3.y
mov r7.z, r4.y
dp3 r6.y, r5.xyzx, r7.xyzx
mov r4.x, r0.x
mov r4.y, r3.z
dp3 r6.z, r5.xyzx, r4.xyzx
dp3 r0.x, r6.xyzx, r6.xyzx
rsq r0.x, r0.x
mul r0.xyw, r0.xxxx, r6.xyxz
mov o1.z, -r0.w
mad r0.w, r0.w, l(-8.000000), l(8.000000)
sqrt r0.w, r0.w
div r0.xy, r0.xyxx, r0.wwww
add o1.xy, r0.xyxx, l(0.500000, 0.500000, 0.000000, 0.000000)
mul r0.x, r4.w, cb2[3].x
mul r0.x, r0.x, l(0.020000)
sqrt o2.z, r0.x
mov_sat o2.w, cb2[3].y
mov o0.xyz, r2.xyzx
mov o0.w, r0.z
mov o1.w, r0.z
mov o2.x, l(0)
mul o2.y, cb2[3].y, l(0.00392156886)
mov o3.xy, r1.yzyy
mov o3.z, l(0)
mov o3.w, r0.z
ret 
// Approximately 0 instruction slots used
