//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.16384
//
//   using 3Dmigoto v1.3.15 on Wed Mar 13 10:22:58 2019
//
//
// Buffer Definitions:
//
// cbuffer $Globals
// {
//
//   float4 litDir[4];                  // Offset:    0 Size:    64
//   float4 litCol[4];                  // Offset:   64 Size:    64
//   float4 litOcc;                     // Offset:  128 Size:    16
//   float4 ambLit;                     // Offset:  144 Size:    16
//   int nDirLit;                       // Offset:  160 Size:     4
//   float4 vEye;                       // Offset:  176 Size:    16
//   float2 vOccRate;                   // Offset:  192 Size:     8
//      = 0x3f800000 0x3f800000
//   float4 vClstZPrm;                  // Offset:  208 Size:    16
//   int nClstPtch[2];                  // Offset:  224 Size:    20
//   float fClstScl;                    // Offset:  244 Size:     4 [unused]
//   float2 vFadeDist;                  // Offset:  248 Size:     8
//   float3 vCameraPos;                 // Offset:  256 Size:    12
//   float3 vCameraDir;                 // Offset:  272 Size:    12
//   float2 vD2Z;                       // Offset:  288 Size:     8
//   float4 mRrW2T[3];                  // Offset:  304 Size:    48
//   row_major float4x4 mV2W;           // Offset:  352 Size:    64
//   row_major float4x4 mP2W;           // Offset:  416 Size:    64
//   float fAmbMapsDORate;              // Offset:  480 Size:     4
//      = 0x00000000
//   float4 vAmbDifScl;                 // Offset:  496 Size:    16
//      = 0x3f800000 0x3f800000 0x3f800000 0x3f800000
//   float4 vAmbSpcScl;                 // Offset:  512 Size:    16
//      = 0x3f800000 0x3f800000 0x3f800000 0x3f800000
//   float4 vTsbViewPort;               // Offset:  528 Size:    16
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// __smpsIES                         sampler      NA          NA    0        1
// __smpsDepthMap                    sampler      NA          NA    1        1
// __smpsGxAmbLut                    sampler      NA          NA    2        1
// __smpsAmbSpc                      sampler      NA          NA    3        1
// __smpsTrnsSpc                     sampler      NA          NA    4        1
// sIES                              texture  float4     2darray    0        1
// sDepthMap                         texture  float4          2d    1        1
// sGxAmbLut                         texture  float4          2d    2        1
// sAmbSpc                           texture  float4        cube    3        1
// sTrnsSpc                          texture  float4          2d    4        1
// sDepth                            texture  float4          2d    5        1
// sGBuf0                            texture  float4          2d    6        1
// sGBuf1                            texture  float4     2darray    7        1
// sGBuf2                            texture  float4          2d    8        1
// sGBuf3                            texture  float4     2darray    9        1
// tCllLightIndices                  texture    uint         buf   16        1
// tCllLightPositions                texture  float4         buf   17        1
// tCllLightAttributes               texture  float3         buf   18        1
// tCllLightExAttributes             texture    uint         buf   19        1
// tCllSptLightAttributes            texture  float3         buf   20        1
// tCllSptLightExAttributes          texture    uint         buf   21        1
// $Globals                          cbuffer      NA          NA    0        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Position              0   xyzw        0      POS   float   xy
// TEXCOORD                 0   xyzw        1     NONE   float   xy w
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Target                0   xyzw        0   TARGET   float   xyzw
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer cb0[34], immediateIndexed
dcl_sampler s0, mode_default
dcl_sampler s1, mode_default
dcl_sampler s2, mode_default
dcl_sampler s3, mode_default
dcl_sampler s4, mode_default
dcl_resource_texture2darray (float,float,float,float) t0
dcl_resource_texture2d (float,float,float,float) t1
dcl_resource_texture2d (float,float,float,float) t2
dcl_resource_texturecube (float,float,float,float) t3
dcl_resource_texture2d (float,float,float,float) t4
dcl_resource_texture2d (float,float,float,float) t5
dcl_resource_texture2d (float,float,float,float) t6
dcl_resource_texture2darray (float,float,float,float) t7
dcl_resource_texture2d (float,float,float,float) t8
dcl_resource_texture2darray (float,float,float,float) t9
dcl_resource_buffer (uint,uint,uint,uint) t16
dcl_resource_buffer (float,float,float,float) t17
dcl_resource_buffer (float,float,float,float) t18
dcl_resource_buffer (uint,uint,uint,uint) t19
dcl_resource_buffer (float,float,float,float) t20
dcl_resource_buffer (uint,uint,uint,uint) t21
dcl_input_ps_siv linear noperspective v0.xy, position
dcl_input_ps linear v1.xyw
dcl_output o0.xyzw
dcl_temps 35

// mP2W inversed with inverse-cs, i.e. mW2P
dcl_constantbuffer cb13[4], immediateIndexed

dcl_resource_texture2d (float,float,float,float) t121
ld_indexable(texture2d)(float,float,float,float) r32.xyzw, l(0, 0, 0, 0), t121.xyzw

ftoi r0.xy, v0.xyxx
mov r0.zw, l(0,0,1,0)
ld_indexable(texture2d)(float,float,float,float) r1.xyzw, r0.xyww, t6.xyzw
ld_indexable(texture2darray)(float,float,float,float) r2.xyz, r0.xyww, t7.xyzw
ld_indexable(texture2d)(float,float,float,float) r3.xyzw, r0.xyww, t8.xyzw
ld_indexable(texture2darray)(float,float,float,float) r4.xyz, r0.xyww, t9.xyzw
ld_indexable(texture2darray)(float,float,float,float) r5.xyz, r0.xyzw, t9.xyzw
mov r0.z, l(3)
ld_indexable(texture2darray)(float,float,float,float) r6.xyz, r0.xyzw, t7.xywz
ld_indexable(texture2d)(float,float,float,float) r0.x, r0.xyww, t5.xyzw
// mP2W
mul r7.xyzw, v1.yyyy, cb0[27].xyzw
mad r7.xyzw, v1.xxxx, cb0[26].xyzw, r7.xyzw
mad r7.xyzw, r0.xxxx, cb0[28].xyzw, r7.xyzw
add r7.xyzw, r7.xyzw, cb0[29].xyzw
div r0.yzw, r7.xxyz, r7.wwww

if_nz cb13[0].x
	// mW2P
	mul r33.xyzw, r0.yyyy, cb13[0].xyzw
	mad r33.xyzw, r0.zzzz, cb13[1].xyzw, r33.xyzw
	mad r33.xyzw, r0.wwww, cb13[2].xyzw, r33.xyzw
	add r33.xyzw, r33.xyzw, cb13[3].xyzw
	// Stereo correct
	add r32.w, r33.w, -r32.y
	mad r33.x, -r32.w, r32.x, r33.x
	// mP2W
	mul r34.xyzw, r33.xxxx, cb0[26].xyzw
	mad r34.xyzw, r33.yyyy, cb0[27].xyzw, r34.xyzw
	mad r34.xyzw, r33.zzzz, cb0[28].xyzw, r34.xyzw
	mad r34.xyzw, r33.wwww, cb0[29].xyzw, r34.xyzw
	// Do not adjust o0 - breaks refraction
	div r34.xyz, r34.xyzw, r34.wwww

	// r7 affects reflections, r0 affects refraction. Use the corrected value for r7 only:
	add r7.xyz, -r34.xyzx, cb0[11].xyzx
else
	add r7.xyz, -r0.yzwy, cb0[11].xyzx
endif

// Correct reflections by stereoising eye position (must be at surface depth from above adjustment)
mul r34.x, r32.x, -r32.y
mul r34.xyzw, r34.xxxx, cb0[26].xyzw
add r7.xyz, r7.xyzw, -r34.xyzw

dp3 r2.w, r7.xyzx, r7.xyzx
rsq r2.w, r2.w
mul r8.xyz, r2.wwww, r7.xyzx
mad r3.xy, r3.xyxx, l(2.000000, 2.000000, 0.000000, 0.000000), l(-1.000000, -1.000000, 0.000000, 0.000000)
add r9.xyz, -|r3.xyxx|, l(1.000000, 1.000000, 1.000000, 0.000000)
add r10.z, -|r3.y|, r9.x
ge r4.w, r10.z, l(0.000000)
ge r9.xw, r3.xxxy, l(0.000000, 0.000000, 0.000000, 0.000000)
movc r9.xw, r9.xxxw, l(1.000000,0,0,1.000000), l(-1.000000,0,0,-1.000000)
mul r9.xy, r9.xwxx, r9.yzyy
movc r10.xy, r4.wwww, r3.xyxx, r9.xyxx
dp3 r3.x, r10.xyzx, r10.xyzx
rsq r3.x, r3.x
mul r9.xyz, r3.xxxx, r10.xyzx
mul r10.xyz, r9.yyyy, cb0[23].xyzx
mad r9.xyw, r9.xxxx, cb0[22].xyxz, r10.xyxz
mad r9.xyz, r9.zzzz, cb0[24].xyzx, r9.xywx
mul r3.xyz, r3.zwwz, l(65535.000000, 65535.000000, 65535.000000, 0.000000)
ftou r3.xyz, r3.xyzx
ushr r3.xyz, r3.xyzx, l(8, 8, 8, 0)
utof r3.xyz, r3.xyzx
mul r10.yzw, r3.xxyz, l(0.000000, 0.00392156886, 0.00784313772, 0.00392156886)
mad r3.x, r3.x, l(0.00392156886), l(1.000000)
add r3.yzw, -r0.yyzw, cb0[16].xxyz
max r11.xyz, r1.xyzx, l(0.000100, 0.000100, 0.000100, 0.000000)
min r11.xyz, r11.xyzx, l(0.999900, 0.999900, 0.999900, 0.000000)
log r11.xyz, r11.xyzx
mul r11.xyz, r11.xyzx, l(0.693147182, 0.693147182, 0.693147182, 0.000000)
max r5.yw, r5.yyyz, l(0.000000, 0.000100, 0.000000, 0.000000)
div r11.xyz, -r11.xyzx, r5.yyyy
mul r11.xyz, r5.wwww, -r11.xyzx
mul r11.xyz, r11.xyzx, l(1.442695, 1.442695, 1.442695, 0.000000)
exp r11.xyz, r11.xyzx
dp3 r10.x, r9.xyzx, r8.xyzx
mov_sat r4.w, r10.x
add r5.y, r1.w, r4.w
mad r5.y, r5.y, r5.y, r1.w
add_sat r5.y, r5.y, l(-1.000000)
dp3 r12.x, r9.xyzx, -cb0[0].xyzx
lt r5.w, r12.x, l(0.000000)
lt r6.w, l(1.000000), r3.x
and r5.w, r5.w, r6.w
add r7.w, r12.x, r12.x
mad r13.yzw, r9.xxyz, r7.wwww, cb0[0].xxyz
mov r13.x, -r12.x
mul r14.xyz, r11.xyzx, cb0[4].xyzx
mad r15.xyz, r7.xyzx, r2.wwww, -r13.yzwy
dp3 r7.w, r15.xyzx, r15.xyzx
rsq r7.w, r7.w
mul r15.xyz, r7.wwww, r15.xyzx
dp3_sat r7.w, r8.xyzx, r15.xyzx
add r15.xyz, -r2.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
add r7.w, -r7.w, l(1.000000)
mul r8.w, r7.w, r7.w
mul r8.w, r8.w, r8.w
mul r7.w, r7.w, r8.w
mad r16.xyz, r15.xyzx, r7.wwww, r2.xyzx
add r17.xyz, -r16.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
add r3.x, -r3.x, l(2.000000)
mul r18.xyz, r3.xxxx, r17.xyzx
mad r16.xyz, r17.xyzx, r3.xxxx, r16.xyzx
add r16.xyz, -r16.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
mul r17.xyz, r10.yyyy, r18.xyzx
movc r16.xyz, r5.wwww, r16.yzxy, l(-1.000000,-1.000000,-1.000000,0)
movc r17.xyz, r5.wwww, r17.xyzx, l(-1.000000,-1.000000,-1.000000,0)
movc r14.xyz, r5.wwww, r14.xyzx, cb0[4].xyzx
mov r12.yzw, cb0[0].xxyz
movc r13.xyzw, r5.wwww, r13.xyzw, r12.xyzw
mad r13.yzw, r7.xxyz, r2.wwww, -r13.yyzw
dp3 r5.w, r13.yzwy, r13.yzwy
rsq r5.w, r5.w
mul r13.yzw, r5.wwww, r13.yyzw
dp3 r5.w, r8.xyzx, r13.yzwy
ge r7.w, r16.z, l(0.000000)
mov_sat r8.w, r5.w
add r8.w, -r8.w, l(1.000000)
mul r9.w, r8.w, r8.w
mul r9.w, r9.w, r9.w
mul r8.w, r8.w, r9.w
mad r18.xyz, r15.xyzx, r8.wwww, r2.xyzx
movc r18.xyz, r7.wwww, r16.zxyz, r18.xyzx
mul r8.w, r10.z, r10.z
mul r9.w, r8.w, r8.w
dp3 r10.z, r9.xyzx, r13.yzwy
mul r11.w, r9.w, r9.w
mul r10.z, r10.z, r10.z
mad r12.z, r9.w, r9.w, l(-1.000000)
mad r10.z, r10.z, r12.z, l(1.000000)
max r10.z, r10.z, l(0.000100)
mul r10.z, r10.z, r10.z
mul r10.z, r10.z, l(4.000000)
div r10.z, r11.w, r10.z
mul r12.w, r9.w, l(0.500000)
mad r9.w, -r9.w, l(0.500000), l(1.000000)
mad r5.w, r5.w, r9.w, r12.w
mul r5.w, r5.w, r5.w
div r5.w, l(1.000000, 1.000000, 1.000000, 1.000000), r5.w
mul r5.w, r5.w, r10.z
mul r13.yzw, r5.wwww, r18.xxyz
mul r13.yzw, r14.xxyz, r13.yyzw
mov_sat r13.x, r13.x
mul r18.xy, cb0[8].xxxx, cb0[12].yxyy
mad r18.zw, -cb0[12].yyyx, cb0[8].xxxx, l(0.000000, 0.000000, 1.000000, 1.000000)
mad r5.w, r5.y, r18.x, r18.z
mul r5.w, r5.w, r13.x
mul r13.yzw, r5.wwww, r13.yyzw
mul r14.xyz, r13.xxxx, r14.xyzx
mul r19.xyz, r3.xxxx, r15.xyzx
movc r20.xyz, r7.wwww, r17.xyzx, r19.xyzx
mul r14.xyz, r14.xyzx, r20.xyzx
mad r5.w, r1.w, r18.y, r18.w
mul r14.xyz, r5.wwww, r14.xyzx
mul r14.xyz, r6.zzzz, r14.xyzx
mul r13.xyz, r6.zzzz, r13.yzwy
ilt r5.w, l(0), cb0[10].x
if_nz r5.w
  dp3 r18.x, r9.xyzx, -cb0[1].xyzx
  lt r5.w, r18.x, l(0.000000)
  and r5.w, r6.w, r5.w
  add r7.w, r18.x, r18.x
  mad r20.yzw, r9.xxyz, r7.wwww, cb0[1].xxyz
  mov r20.x, -r18.x
  mul r21.xyz, r11.xyzx, cb0[5].xyzx
  mad r22.xyz, r7.xyzx, r2.wwww, -r20.yzwy
  dp3 r7.w, r22.xyzx, r22.xyzx
  rsq r7.w, r7.w
  mul r22.xyz, r7.wwww, r22.xyzx
  dp3_sat r7.w, r8.xyzx, r22.xyzx
  add r7.w, -r7.w, l(1.000000)
  mul r10.z, r7.w, r7.w
  mul r10.z, r10.z, r10.z
  mul r7.w, r7.w, r10.z
  mad r22.xyz, r15.xyzx, r7.wwww, r2.xyzx
  add r23.xyz, -r22.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
  mul r24.xyz, r3.xxxx, r23.xyzx
  mad r22.xyz, r23.xyzx, r3.xxxx, r22.xyzx
  add r22.xyz, -r22.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
  mul r23.xyz, r10.yyyy, r24.xyzx
  mov r16.w, l(-1.000000)
  movc r16.xyz, r5.wwww, r22.yzxy, r16.xywx
  movc r17.xyz, r5.wwww, r23.xyzx, r17.xyzx
  movc r21.xyz, r5.wwww, r21.xyzx, cb0[5].xyzx
  mov r18.yzw, cb0[1].xxyz
  movc r18.xyzw, r5.wwww, r20.xyzw, r18.xyzw
  mad r18.yzw, r7.xxyz, r2.wwww, -r18.yyzw
  dp3 r5.w, r18.yzwy, r18.yzwy
  rsq r5.w, r5.w
  mul r18.yzw, r5.wwww, r18.yyzw
  dp3 r5.w, r8.xyzx, r18.yzwy
  ge r7.w, r16.z, l(0.000000)
  mov_sat r10.z, r5.w
  add r10.z, -r10.z, l(1.000000)
  mul r13.w, r10.z, r10.z
  mul r13.w, r13.w, r13.w
  mul r10.z, r10.z, r13.w
  mad r20.xyz, r15.xyzx, r10.zzzz, r2.xyzx
  movc r20.xyz, r7.wwww, r16.zxyz, r20.xyzx
  dp3 r10.z, r9.xyzx, r18.yzwy
  mul r10.z, r10.z, r10.z
  mad r10.z, r10.z, r12.z, l(1.000000)
  max r10.z, r10.z, l(0.000100)
  mul r10.z, r10.z, r10.z
  mul r10.z, r10.z, l(4.000000)
  div r10.z, r11.w, r10.z
  mad r5.w, r5.w, r9.w, r12.w
  mul r5.w, r5.w, r5.w
  div r5.w, l(1.000000, 1.000000, 1.000000, 1.000000), r5.w
  mul r5.w, r5.w, r10.z
  mul r18.yzw, r5.wwww, r20.xxyz
  mul r18.yzw, r21.xxyz, r18.yyzw
  mov_sat r18.x, r18.x
  mul r20.xy, cb0[8].yyyy, cb0[12].yxyy
  mad r20.zw, -cb0[12].yyyx, cb0[8].yyyy, l(0.000000, 0.000000, 1.000000, 1.000000)
  mad r5.w, r5.y, r20.x, r20.z
  mul r5.w, r5.w, r18.x
  mad r13.xyz, r18.yzwy, r5.wwww, r13.xyzx
  mul r18.xyz, r18.xxxx, r21.xyzx
  movc r21.xyz, r7.wwww, r17.xyzx, r19.xyzx
  mul r18.xyz, r18.xyzx, r21.xyzx
  mad r5.w, r1.w, r20.y, r20.w
  mad r14.xyz, r18.xyzx, r5.wwww, r14.xyzx
  ilt r5.w, l(1), cb0[10].x
  if_nz r5.w
    dp3 r18.x, r9.xyzx, -cb0[2].xyzx
    lt r5.w, r18.x, l(0.000000)
    and r5.w, r6.w, r5.w
    add r7.w, r18.x, r18.x
    mad r20.yzw, r9.xxyz, r7.wwww, cb0[2].xxyz
    mov r20.x, -r18.x
    mul r21.xyz, r11.xyzx, cb0[6].xyzx
    mad r22.xyz, r7.xyzx, r2.wwww, -r20.yzwy
    dp3 r7.w, r22.xyzx, r22.xyzx
    rsq r7.w, r7.w
    mul r22.xyz, r7.wwww, r22.xyzx
    dp3_sat r7.w, r8.xyzx, r22.xyzx
    add r7.w, -r7.w, l(1.000000)
    mul r10.z, r7.w, r7.w
    mul r10.z, r10.z, r10.z
    mul r7.w, r7.w, r10.z
    mad r22.xyz, r15.xyzx, r7.wwww, r2.xyzx
    add r23.xyz, -r22.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
    mul r24.xyz, r3.xxxx, r23.xyzx
    mad r22.xyz, r23.xyzx, r3.xxxx, r22.xyzx
    add r22.xyz, -r22.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
    mul r23.xyz, r10.yyyy, r24.xyzx
    mov r16.w, l(-1.000000)
    movc r16.xyz, r5.wwww, r22.yzxy, r16.xywx
    movc r17.xyz, r5.wwww, r23.xyzx, r17.xyzx
    movc r21.xyz, r5.wwww, r21.xyzx, cb0[6].xyzx
    mov r18.yzw, cb0[2].xxyz
    movc r18.xyzw, r5.wwww, r20.xyzw, r18.xyzw
    mad r18.yzw, r7.xxyz, r2.wwww, -r18.yyzw
    dp3 r5.w, r18.yzwy, r18.yzwy
    rsq r5.w, r5.w
    mul r18.yzw, r5.wwww, r18.yyzw
    dp3 r5.w, r8.xyzx, r18.yzwy
    ge r7.w, r16.z, l(0.000000)
    mov_sat r10.z, r5.w
    add r10.z, -r10.z, l(1.000000)
    mul r13.w, r10.z, r10.z
    mul r13.w, r13.w, r13.w
    mul r10.z, r10.z, r13.w
    mad r20.xyz, r15.xyzx, r10.zzzz, r2.xyzx
    movc r20.xyz, r7.wwww, r16.zxyz, r20.xyzx
    dp3 r10.z, r9.xyzx, r18.yzwy
    mul r10.z, r10.z, r10.z
    mad r10.z, r10.z, r12.z, l(1.000000)
    max r10.z, r10.z, l(0.000100)
    mul r10.z, r10.z, r10.z
    mul r10.z, r10.z, l(4.000000)
    div r10.z, r11.w, r10.z
    mad r5.w, r5.w, r9.w, r12.w
    mul r5.w, r5.w, r5.w
    div r5.w, l(1.000000, 1.000000, 1.000000, 1.000000), r5.w
    mul r5.w, r5.w, r10.z
    mul r18.yzw, r5.wwww, r20.xxyz
    mul r18.yzw, r21.xxyz, r18.yyzw
    mov_sat r18.x, r18.x
    mul r20.xy, cb0[8].zzzz, cb0[12].yxyy
    mad r20.zw, -cb0[12].yyyx, cb0[8].zzzz, l(0.000000, 0.000000, 1.000000, 1.000000)
    mad r5.w, r5.y, r20.x, r20.z
    mul r5.w, r5.w, r18.x
    mad r13.xyz, r18.yzwy, r5.wwww, r13.xyzx
    mul r18.xyz, r18.xxxx, r21.xyzx
    movc r21.xyz, r7.wwww, r17.xyzx, r19.xyzx
    mul r18.xyz, r18.xyzx, r21.xyzx
    mad r5.w, r1.w, r20.y, r20.w
    mad r14.xyz, r18.xyzx, r5.wwww, r14.xyzx
    ilt r5.w, l(2), cb0[10].x
    if_nz r5.w
      dp3 r18.x, r9.xyzx, -cb0[3].xyzx
      lt r5.w, r18.x, l(0.000000)
      and r5.w, r6.w, r5.w
      add r7.w, r18.x, r18.x
      mad r20.yzw, r9.xxyz, r7.wwww, cb0[3].xxyz
      mov r20.x, -r18.x
      mul r21.xyz, r11.xyzx, cb0[7].xyzx
      mad r22.xyz, r7.xyzx, r2.wwww, -r20.yzwy
      dp3 r7.w, r22.xyzx, r22.xyzx
      rsq r7.w, r7.w
      mul r22.xyz, r7.wwww, r22.xyzx
      dp3_sat r7.w, r8.xyzx, r22.xyzx
      add r7.w, -r7.w, l(1.000000)
      mul r10.z, r7.w, r7.w
      mul r10.z, r10.z, r10.z
      mul r7.w, r7.w, r10.z
      mad r22.xyz, r15.xyzx, r7.wwww, r2.xyzx
      add r23.xyz, -r22.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
      mul r24.xyz, r3.xxxx, r23.xyzx
      mad r22.xyz, r23.xyzx, r3.xxxx, r22.xyzx
      add r22.xyz, -r22.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
      mul r23.xyz, r10.yyyy, r24.xyzx
      mov r16.w, l(-1.000000)
      movc r16.xyz, r5.wwww, r22.yzxy, r16.xywx
      movc r17.xyz, r5.wwww, r23.xyzx, r17.xyzx
      movc r21.xyz, r5.wwww, r21.xyzx, cb0[7].xyzx
      mov r18.yzw, cb0[3].xxyz
      movc r18.xyzw, r5.wwww, r20.xyzw, r18.xyzw
      mad r18.yzw, r7.xxyz, r2.wwww, -r18.yyzw
      dp3 r5.w, r18.yzwy, r18.yzwy
      rsq r5.w, r5.w
      mul r18.yzw, r5.wwww, r18.yyzw
      dp3 r5.w, r8.xyzx, r18.yzwy
      ge r7.w, r16.z, l(0.000000)
      mov_sat r10.z, r5.w
      add r10.z, -r10.z, l(1.000000)
      mul r13.w, r10.z, r10.z
      mul r13.w, r13.w, r13.w
      mul r10.z, r10.z, r13.w
      mad r20.xyz, r15.xyzx, r10.zzzz, r2.xyzx
      movc r20.xyz, r7.wwww, r16.zxyz, r20.xyzx
      dp3 r10.z, r9.xyzx, r18.yzwy
      mul r10.z, r10.z, r10.z
      mad r10.z, r10.z, r12.z, l(1.000000)
      max r10.z, r10.z, l(0.000100)
      mul r10.z, r10.z, r10.z
      mul r10.z, r10.z, l(4.000000)
      div r10.z, r11.w, r10.z
      mad r5.w, r5.w, r9.w, r12.w
      mul r5.w, r5.w, r5.w
      div r5.w, l(1.000000, 1.000000, 1.000000, 1.000000), r5.w
      mul r5.w, r5.w, r10.z
      mul r18.yzw, r5.wwww, r20.xxyz
      mul r18.yzw, r21.xxyz, r18.yyzw
      mov_sat r18.x, r18.x
      mul r16.zw, cb0[8].wwww, cb0[12].yyyx
      mad r20.xy, -cb0[12].yxyy, cb0[8].wwww, l(1.000000, 1.000000, 0.000000, 0.000000)
      mad r5.w, r5.y, r16.z, r20.x
      mul r5.w, r5.w, r18.x
      mad r13.xyz, r18.yzwy, r5.wwww, r13.xyzx
      mul r18.xyz, r18.xxxx, r21.xyzx
      movc r20.xzw, r7.wwww, r17.xxyz, r19.xxyz
      mul r18.xyz, r18.xyzx, r20.xzwx
      mad r5.w, r1.w, r16.w, r20.y
      mad r14.xyz, r18.xyzx, r5.wwww, r14.xyzx
    endif
  endif
endif
mad r0.x, r0.x, cb0[13].x, cb0[13].y
log r5.w, r0.x
mad r5.w, r5.w, cb0[13].z, cb0[13].w
max r5.w, r5.w, l(0.000000)
ftou r5.w, r5.w
ult r7.w, r5.w, l(16)
if_nz r7.w
  mul r16.zw, v0.xxxy, l(0.000000, 0.000000, 0.015625, 0.015625)
  ftou r16.zw, r16.zzzw
  imul null, r7.w, r16.w, cb0[14].x
  imad r5.w, cb0[15].x, r5.w, r7.w
  iadd r5.w, r16.z, r5.w
  div r0.x, l(-1.000000), r0.x
  add r7.w, -cb0[15].w, cb0[15].z
  add r0.x, r0.x, -cb0[15].w
  div r7.w, l(1.000000, 1.000000, 1.000000, 1.000000), r7.w
  mul_sat r0.x, r0.x, r7.w
  mad r7.w, r0.x, l(-2.000000), l(3.000000)
  mul r0.x, r0.x, r0.x
  mul r0.x, r0.x, r7.w
  ishl r7.w, r5.w, l(2)
  ld_indexable(buffer)(uint,uint,uint,uint) r7.w, r7.wwww, t16.yzwx
  bfi r18.xyz, l(30, 30, 30, 0), l(2, 2, 2, 0), r5.wwww, l(1, 2, 3, 0)
  ld_indexable(buffer)(uint,uint,uint,uint) r5.w, r18.xxxx, t16.yzwx
  ishl r5.w, r5.w, l(16)
  or r5.w, r5.w, r7.w
  ld_indexable(buffer)(uint,uint,uint,uint) r7.w, r18.yyyy, t16.yzwx
  ld_indexable(buffer)(uint,uint,uint,uint) r10.z, r18.zzzz, t16.yzxw
  mov r18.x, l(1.000000)
  mov r20.x, l(-1.000000)
  mov r21.xyz, r14.xyzx
  mov r22.xyz, r17.xyzx
  mov r23.xyz, r13.xyzx
  mov r24.xy, r16.xyxx
  mov r13.w, l(0)
  loop
    uge r14.w, r13.w, r7.w
    breakc_nz r14.w
    iadd r14.w, r5.w, r13.w
    ld_indexable(buffer)(uint,uint,uint,uint) r14.w, r14.wwww, t16.yzwx
    ld_indexable(buffer)(float,float,float,float) r25.xyzw, r14.wwww, t17.xyzw
    mul r15.w, r25.w, r25.w
    add r25.xyz, -r0.yzwy, r25.xyzx
    dp3 r18.z, r25.xyzx, r25.xyzx
    lt r16.z, r18.z, r15.w
    if_nz r16.z
      imul null, r16.z, r14.w, l(3)
      ld_indexable(buffer)(float,float,float,float) r26.xyz, r16.zzzz, t18.xyzw
      imad r16.w, l(3), r14.w, l(1)
      ld_indexable(buffer)(float,float,float,float) r27.xyz, r16.wwww, t18.xyzw
      mul r26.xyz, r0.xxxx, r26.xyzx
      ld_indexable(buffer)(uint,uint,uint,uint) r16.w, r16.wwww, t19.yzwx
      utof r16.w, r16.w
      mul r16.w, r16.w, l(0.00392156886)
      ld_indexable(buffer)(uint,uint,uint,uint) r16.z, r16.zzzz, t19.yzxw
      rsq r17.w, r18.z
      mul r28.xyz, r17.wwww, -r25.xyzx
      ieq r18.w, r16.z, l(3)
      if_nz r18.w
        imad r14.w, l(3), r14.w, l(2)
        ld_indexable(buffer)(uint,uint,uint,uint) r18.w, r14.wwww, t19.yzwx
        ld_indexable(buffer)(float,float,float,float) r29.xyz, r14.wwww, t18.xyzw
        dp3 r14.w, -r25.xyzx, -r25.xyzx
        rsq r14.w, r14.w
        mul r25.xyz, r14.wwww, -r25.xyzx
        dp3 r14.w, r25.xyzx, r29.xyzx
        mad r30.x, r14.w, l(-0.500000), l(0.500000)
        dp3 r19.w, r25.xyzx, r27.xyzx
        mad r14.w, -r14.w, r14.w, l(1.000000)
        rsq r14.w, r14.w
        mul r14.w, r14.w, r19.w
        mul r31.xyz, r27.zxyz, r29.yzxy
        mad r29.xyz, r27.yzxy, r29.zxyz, -r31.xyzx
        dp3 r19.w, r29.xyzx, r25.xyzx
        ge r19.w, r19.w, l(0.000000)
        mad r25.xy, r14.wwww, l(-0.250000, 0.250000, 0.000000, 0.000000), l(0.250000, 0.750000, 0.000000, 0.000000)
        movc r30.y, r19.w, r25.x, r25.y
        utof r30.z, r18.w
        sample_l_indexable(texture2darray)(float,float,float,float) r14.w, r30.xyzx, t0.yzwx, s0, l(0.000000)
        mul r14.w, r15.w, r14.w
        div r14.w, r14.w, r18.z
        div r15.w, r18.z, r15.w
        add r15.w, -r15.w, l(1.000000)
        max r15.w, r15.w, l(0.000000)
        mul r14.w, r14.w, r15.w
      else
        ieq r15.w, r16.z, l(2)
        mul r16.z, -r18.z, r27.x
        mul r16.z, r16.z, l(1.442695)
        exp r16.z, r16.z
        mul_sat r16.z, r16.z, r27.y
        mul r18.y, r17.w, r18.z
        dp3 r17.w, r27.xyzx, r18.xyzx
        div r17.w, l(1.000000, 1.000000, 1.000000, 1.000000), r17.w
        movc r14.w, r15.w, r16.z, r17.w
      endif
      mul r18.yzw, r26.xxyz, r14.wwww
      dp3 r14.w, r9.xyzx, -r28.xyzx
      lt r15.w, r14.w, l(0.000000)
      and r15.w, r6.w, r15.w
      if_nz r15.w
        add r15.w, r14.w, r14.w
        mad r28.xyz, r9.xyzx, r15.wwww, r28.xyzx
        mul r18.yzw, r11.xxyz, r18.yyzw
        mad r25.xyz, r7.xyzx, r2.wwww, -r28.xyzx
        dp3 r15.w, r25.xyzx, r25.xyzx
        rsq r15.w, r15.w
        mul r25.xyz, r15.wwww, r25.xyzx
        dp3_sat r15.w, r8.xyzx, r25.xyzx
        add r15.w, -r15.w, l(1.000000)
        mul r16.z, r15.w, r15.w
        mul r16.z, r16.z, r16.z
        mul r15.w, r15.w, r16.z
        mad r25.xyz, r15.xyzx, r15.wwww, r2.xyzx
        add r26.xyz, -r25.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
        mul r27.xyz, r3.xxxx, r26.xyzx
        mad r25.xyz, r26.xyzx, r3.xxxx, r25.xyzx
        add r24.xyz, -r25.yzxy, l(1.000000, 1.000000, 1.000000, 0.000000)
        mul r22.xyz, r10.yyyy, r27.xyzx
        mov r14.w, -r14.w
      else
        mov r20.yz, r24.xxyx
        mov r24.xyz, r20.yzxy
      endif
      mad r20.yzw, r7.xxyz, r2.wwww, -r28.xxyz
      dp3 r15.w, r20.yzwy, r20.yzwy
      rsq r15.w, r15.w
      mul r20.yzw, r15.wwww, r20.yyzw
      dp3 r15.w, r8.xyzx, r20.yzwy
      ge r16.z, r24.z, l(0.000000)
      mov_sat r17.w, r15.w
      add r17.w, -r17.w, l(1.000000)
      mul r19.w, r17.w, r17.w
      mul r19.w, r19.w, r19.w
      mul r17.w, r17.w, r19.w
      mad r25.xyz, r15.xyzx, r17.wwww, r2.xyzx
      movc r25.xyz, r16.zzzz, r24.zxyz, r25.xyzx
      dp3 r17.w, r9.xyzx, r20.yzwy
      mul r17.w, r17.w, r17.w
      mad r17.w, r17.w, r12.z, l(1.000000)
      max r17.w, r17.w, l(0.000100)
      mul r17.w, r17.w, r17.w
      mul r17.w, r17.w, l(4.000000)
      div r17.w, r11.w, r17.w
      mad r15.w, r15.w, r9.w, r12.w
      mul r15.w, r15.w, r15.w
      div r15.w, l(1.000000, 1.000000, 1.000000, 1.000000), r15.w
      mul r15.w, r15.w, r17.w
      mul r20.yzw, r15.wwww, r25.xxyz
      mul r20.yzw, r18.yyzw, r20.yyzw
      mov_sat r14.w, r14.w
      mul r24.zw, r16.wwww, cb0[12].yyyx
      mad r25.xy, -cb0[12].yxyy, r16.wwww, l(1.000000, 1.000000, 0.000000, 0.000000)
      mad r15.w, r5.y, r24.z, r25.x
      mul r15.w, r14.w, r15.w
      mad r23.xyz, r20.yzwy, r15.wwww, r23.xyzx
      mul r18.yzw, r14.wwww, r18.yyzw
      movc r20.yzw, r16.zzzz, r22.xxyz, r19.xxyz
      mul r18.yzw, r18.yyzw, r20.yyzw
      mad r14.w, r1.w, r24.w, r25.y
      mad r21.xyz, r18.yzwy, r14.wwww, r21.xyzx
    endif
    iadd r13.w, r13.w, l(1)
  endloop
  iadd r5.w, r5.w, r7.w
  mov r16.x, l(1.000000)
  mov r17.x, l(-1.000000)
  mov r14.xyz, r21.xyzx
  mov r18.xyz, r22.xyzx
  mov r13.xyz, r23.xyzx
  mov r20.xy, r24.xyxx
  mov r7.w, l(0)
  loop
    uge r13.w, r7.w, r10.z
    breakc_nz r13.w
    iadd r13.w, r5.w, r7.w
    ld_indexable(buffer)(uint,uint,uint,uint) r13.w, r13.wwww, t16.yzwx
    imul null, r14.w, r13.w, l(5)
    ld_indexable(buffer)(float,float,float,float) r25.xyz, r14.wwww, t20.xyzw
    imad r14.w, l(5), r13.w, l(4)
    ld_indexable(buffer)(float,float,float,float) r26.xyz, r14.wwww, t20.xyzw
    add r25.xyz, -r0.yzwy, r25.xyzx
    dp3 r16.z, r25.xyzx, r25.xyzx
    lt r14.w, r16.z, r26.x
    if_nz r14.w
      imad r14.w, l(5), r13.w, l(1)
      ld_indexable(buffer)(float,float,float,float) r27.xyz, r14.wwww, t20.xyzw
      rsq r14.w, r16.z
      mul r28.xyz, r14.wwww, -r25.xyzx
      dp3 r15.w, -r28.xyzx, r27.xyzx
      mad_sat r15.w, r15.w, r26.z, r26.y
      lt r16.w, l(0.000000), r15.w
      if_nz r16.w
        imad r24.zw, l(0, 0, 5, 5), r13.wwww, l(0, 0, 2, 3)
        ld_indexable(buffer)(float,float,float,float) r26.yzw, r24.zzzz, t20.wxyz
        ld_indexable(buffer)(float,float,float,float) r29.xyz, r24.wwww, t20.xyzw
        mul r26.yzw, r0.xxxx, r26.yyzw
        imul null, r16.w, r13.w, l(3)
        imad r17.w, l(3), r13.w, l(1)
        ld_indexable(buffer)(uint,uint,uint,uint) r17.w, r17.wwww, t21.yzwx
        utof r17.w, r17.w
        ld_indexable(buffer)(uint,uint,uint,uint) r16.w, r16.wwww, t21.yzwx
        ieq r18.w, r16.w, l(3)
        if_nz r18.w
          imad r13.w, l(3), r13.w, l(2)
          ld_indexable(buffer)(uint,uint,uint,uint) r13.w, r13.wwww, t21.yzwx
          dp3 r18.w, -r25.xyzx, -r25.xyzx
          rsq r18.w, r18.w
          mul r25.xyz, r18.wwww, -r25.xyzx
          dp3 r18.w, r25.xyzx, r27.xyzx
          mad r30.x, r18.w, l(-0.500000), l(0.500000)
          dp3 r19.w, r25.xyzx, r29.xyzx
          mad r18.w, -r18.w, r18.w, l(1.000000)
          rsq r18.w, r18.w
          mul r18.w, r18.w, r19.w
          mul r31.xyz, r27.yzxy, r29.zxyz
          mad r27.xyz, r29.yzxy, r27.zxyz, -r31.xyzx
          dp3 r19.w, r27.xyzx, r25.xyzx
          ge r19.w, r19.w, l(0.000000)
          mad r24.zw, r18.wwww, l(0.000000, 0.000000, -0.250000, 0.250000), l(0.000000, 0.000000, 0.250000, 0.750000)
          movc r30.y, r19.w, r24.z, r24.w
          utof r30.z, r13.w
          sample_l_indexable(texture2darray)(float,float,float,float) r13.w, r30.xyzx, t0.yzwx, s0, l(0.000000)
          mul r13.w, r26.x, r13.w
          div r13.w, r13.w, r16.z
          div r18.w, r16.z, r26.x
          add_sat r18.w, -r18.w, l(1.000000)
          mul r13.w, r13.w, r18.w
          mul r13.w, r15.w, r13.w
        else
          ieq r16.w, r16.w, l(2)
          mul r18.w, -r16.z, r29.x
          mul r18.w, r18.w, l(1.442695)
          exp r18.w, r18.w
          mul_sat r18.w, r18.w, r29.y
          mul r18.w, r15.w, r18.w
          mul r16.y, r14.w, r16.z
          dp3 r14.w, r16.xyzx, r29.xyzx
          div r14.w, r15.w, r14.w
          movc r13.w, r16.w, r18.w, r14.w
        endif
        mul r16.yzw, r26.yyzw, r13.wwww
        dp3 r13.w, r9.xyzx, -r28.xyzx
        lt r14.w, r13.w, l(0.000000)
        and r14.w, r6.w, r14.w
        if_nz r14.w
          add r14.w, r13.w, r13.w
          mad r28.xyz, r9.xyzx, r14.wwww, r28.xyzx
          mul r16.yzw, r11.xxyz, r16.yyzw
          mad r25.xyz, r7.xyzx, r2.wwww, -r28.xyzx
          dp3 r14.w, r25.xyzx, r25.xyzx
          rsq r14.w, r14.w
          mul r25.xyz, r14.wwww, r25.xyzx
          dp3_sat r14.w, r8.xyzx, r25.xyzx
          add r14.w, -r14.w, l(1.000000)
          mul r15.w, r14.w, r14.w
          mul r15.w, r15.w, r15.w
          mul r14.w, r14.w, r15.w
          mad r25.xyz, r15.xyzx, r14.wwww, r2.xyzx
          add r26.xyz, -r25.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
          mul r27.xyz, r3.xxxx, r26.xyzx
          mad r25.xyz, r26.xyzx, r3.xxxx, r25.xyzx
          add r20.xyz, -r25.yzxy, l(1.000000, 1.000000, 1.000000, 0.000000)
          mul r18.xyz, r10.yyyy, r27.xyzx
          mov r13.w, -r13.w
        else
          mov r17.yz, r20.xxyx
          mov r20.xyz, r17.yzxy
        endif
        mad r25.xyz, r7.xyzx, r2.wwww, -r28.xyzx
        dp3 r14.w, r25.xyzx, r25.xyzx
        rsq r14.w, r14.w
        mul r25.xyz, r14.wwww, r25.xyzx
        dp3 r14.w, r8.xyzx, r25.xyzx
        ge r15.w, r20.z, l(0.000000)
        mov_sat r17.y, r14.w
        add r17.y, -r17.y, l(1.000000)
        mul r17.z, r17.y, r17.y
        mul r17.z, r17.z, r17.z
        mul r17.y, r17.z, r17.y
        mad r26.xyz, r15.xyzx, r17.yyyy, r2.xyzx
        movc r26.xyz, r15.wwww, r20.zxyz, r26.xyzx
        dp3 r17.y, r9.xyzx, r25.xyzx
        mul r17.y, r17.y, r17.y
        mad r17.y, r17.y, r12.z, l(1.000000)
        max r17.y, r17.y, l(0.000100)
        mul r17.y, r17.y, r17.y
        mul r17.yw, r17.yyyw, l(0.000000, 4.000000, 0.000000, 0.00392156886)
        div r17.y, r11.w, r17.y
        mad r14.w, r14.w, r9.w, r12.w
        mul r14.w, r14.w, r14.w
        div r14.w, l(1.000000, 1.000000, 1.000000, 1.000000), r14.w
        mul r14.w, r14.w, r17.y
        mul r25.xyz, r14.wwww, r26.xyzx
        mul r25.xyz, r16.yzwy, r25.xyzx
        mov_sat r13.w, r13.w
        mul r17.yz, r17.wwww, cb0[12].yyxy
        mad r20.zw, -cb0[12].yyyx, r17.wwww, l(0.000000, 0.000000, 1.000000, 1.000000)
        mad r14.w, r5.y, r17.y, r20.z
        mul r14.w, r13.w, r14.w
        mad r13.xyz, r25.xyzx, r14.wwww, r13.xyzx
        mul r16.yzw, r13.wwww, r16.yyzw
        movc r25.xyz, r15.wwww, r18.xyzx, r19.xyzx
        mul r16.yzw, r16.yyzw, r25.xxyz
        mad r13.w, r1.w, r17.z, r20.w
        mad r14.xyz, r16.yzwy, r13.wwww, r14.xyzx
      endif
    endif
    iadd r7.w, r7.w, l(1)
  endloop
endif
ne r0.x, cb0[30].x, l(0.000000)
dp3 r2.w, -r8.xyzx, r9.xyzx
add r2.w, r2.w, r2.w
mad r7.xyz, r9.xyzx, -r2.wwww, -r8.xyzx
mov r8.x, -r9.y
mov r8.y, -r7.y
mov_sat r8.xy, r8.xyxx
dp3_sat r12.y, r7.xyzx, -cb0[0].xyzx
mov_sat r12.x, r12.x
add r8.xy, r8.xyxx, r12.xyxx
mul_sat r8.xy, r8.xyxx, cb0[30].xxxx
add r2.w, r6.z, l(-1.000000)
mad r8.xy, r8.xyxx, r2.wwww, l(1.000000, 1.000000, 0.000000, 0.000000)
movc r8.xy, r0.xxxx, r8.xyxx, l(1.000000,1.000000,0,0)
sample_l_indexable(texturecube)(float,float,float,float) r12.xyz, r9.xyzx, t3.xyzw, s3, l(6.000000)
mul r12.xyz, r8.xxxx, r12.xyzx
mad r12.xyz, r12.xyzx, cb0[31].xyzx, cb0[9].xyzx
add r0.x, -cb0[31].w, l(1.000000)
mad r0.x, r1.w, cb0[31].w, r0.x
add r0.x, r0.x, l(-1.000000)
add r0.x, r0.x, l(1.000000)
add r6.xy, -r6.yxyy, l(1.000000, 1.000000, 0.000000, 0.000000)
mul r2.w, r0.x, r6.x
mul r12.xyz, r2.wwww, r12.xyzx
mad r12.xyz, r12.xyzx, r19.xyzx, r14.xyzx
mul r2.w, r8.w, l(6.000000)
max r7.w, |r7.y|, l(0.008749)
sample_l_indexable(texturecube)(float,float,float,float) r7.xyz, r7.xwzx, t3.xyzw, s3, r2.w
mul r7.xyz, r8.yyyy, r7.xyzx
mul r7.xyz, r7.xyzx, cb0[32].xyzx
sample_indexable(texture2d)(float,float,float,float) r6.xz, r10.xwxx, t2.xzyw, s2
mad r8.xyz, r2.xyzx, r6.xxxx, r6.zzzz
mul r7.xyz, r7.xyzx, r8.xyzx
add r2.w, -cb0[32].w, l(1.000000)
mad r1.w, r1.w, cb0[32].w, r2.w
add r2.w, -r1.w, l(1.000000)
mad r2.w, r5.y, r2.w, r1.w
mad r1.w, r1.w, r2.w, l(-1.000000)
add r1.w, r1.w, l(1.000000)
mul r2.w, r6.y, r1.w
mad r6.xyz, r7.xyzx, r2.wwww, r13.xyzx
div r2.w, l(1.000000, 1.000000, 1.000000, 1.000000), r5.x
dp3 r5.x, r3.yzwy, r3.yzwy
rsq r5.x, r5.x
mul r5.xyw, r3.yzyw, r5.xxxx
dp3_sat r7.x, r9.xyzx, r5.xywx
mad r7.x, -r7.x, r7.x, l(1.000000)
sqrt r7.x, r7.x
mad r7.x, r7.x, r2.w, -r7.x
add r7.yzw, r9.xxyz, l(0.000000, -0.000000, -1.000000, -0.000000)
mul r5.xyw, r2.wwww, r5.xyxw
mad r5.xyw, r7.xxxx, r7.yzyw, -r5.xyxw
dp3 r2.w, r5.xywx, r5.xywx
rsq r2.w, r2.w
mul r5.xyw, r2.wwww, r5.xyxw
mad r5.xyz, r5.xywx, r5.zzzz, r0.yzwy
mov r5.w, l(1.000000)
dp4 r7.x, r5.xyzw, cb0[19].xyzw
dp4 r7.y, r5.xyzw, cb0[20].xyzw
dp4 r0.y, r5.xyzw, cb0[21].xyzw
div r0.yz, r7.xxyx, r0.yyyy
sample_indexable(texture2d)(float,float,float,float) r0.w, r0.yzyy, t1.yzwx, s1
if_nz r6.w
  div r5.xy, v1.xyxx, v1.wwww
  mad r5.xy, r5.xyxx, l(0.500000, -0.500000, 0.000000, 0.000000), l(0.500000, 0.500000, 0.000000, 0.000000)
  dp3 r2.w, -r3.yzwy, cb0[17].xyzx
  add r3.y, -r4.w, l(1.000000)
  mul r3.z, r3.y, r3.y
  mul r3.z, r3.z, r3.z
  mul r3.y, r3.z, r3.y
  mad r2.xyz, r15.xyzx, r3.yyyy, r2.xyzx
  add r3.yzw, -r2.xxyz, l(0.000000, 1.000000, 1.000000, 1.000000)
  mad r2.xyz, r3.yzwy, r3.xxxx, r2.xyzx
  add r2.xyz, -r2.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
  mul r3.xyz, r3.xxxx, r2.xyzx
  mad_sat r0.w, cb0[18].y, r0.w, cb0[18].x
  div r0.w, l(1.000000, 1.000000, 1.000000, 1.000000), r0.w
  lt r0.w, r0.w, r2.w
  movc r0.yz, r0.wwww, r5.xxyx, r0.yyzy
  mad r0.yz, r0.yyzy, cb0[33].zzwz, cb0[33].xxyx
  sample_l_indexable(texture2d)(float,float,float,float) r5.xyz, r0.yzyy, t4.xyzw, s4, l(16.000000)
  mul r5.xyz, r5.xyzx, cb0[31].xyzx
  mul r5.xyz, r0.xxxx, r5.xyzx
  mul r3.xyz, r3.xyzx, r5.xyzx
  mad r12.xyz, r3.xyzx, r11.xyzx, r12.xyzx
  sample_l_indexable(texture2d)(float,float,float,float) r0.xyz, r0.yzyy, t4.xyzw, s4, l(0.000000)
  mul r0.xyz, r0.xyzx, cb0[32].xyzx
  mul r0.xyz, r1.wwww, r0.xyzx
  mul r0.xyz, r2.xyzx, r0.xyzx
  mad r6.xyz, r0.xyzx, r11.xyzx, r6.xyzx
endif
mad r0.xyz, r12.xyzx, r1.xyzx, r4.xyzx
add o0.xyz, r6.xyzx, r0.xyzx
mov o0.w, l(1.000000)
ret
// Approximately 740 instruction slots used
