//c00e7ba807ad187b-ps.txt
//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.17672
//
//   using 3Dmigoto v1.2.27 on Thu Feb 04 21:53:25 2016
//
//
// Buffer Definitions: 
//
// cbuffer DrawableBuffer
// {
//
//   float4 FogColor;                   // Offset:    0 Size:    16 [unused]
//   float4 DebugColor;                 // Offset:   16 Size:    16 [unused]
//   float AlphaThreshold;              // Offset:   32 Size:     4
//   float4 __InstancedMaterialOpacity[256];// Offset:   48 Size:  4096
//
// }
//
// cbuffer SceneBuffer
// {
//
//   row_major float4x4 View;           // Offset:    0 Size:    64
//   row_major float4x4 ScreenMatrix;   // Offset:   64 Size:    64 [unused]
//   float2 DepthExportScale;           // Offset:  128 Size:     8 [unused]
//   float2 __padding0;                 // Offset:  136 Size:     8 [unused]
//   float4 FogParams;                  // Offset:  144 Size:    16 [unused]
//   float3 __CameraPosition;           // Offset:  160 Size:    12 [unused]
//   float __padding12;                 // Offset:  172 Size:     4 [unused]
//   float3 CameraDirection;            // Offset:  176 Size:    12 [unused]
//   float __padding9;                  // Offset:  188 Size:     4 [unused]
//   float3 DepthFactors;               // Offset:  192 Size:    12 [unused]
//   float __padding10;                 // Offset:  204 Size:     4 [unused]
//   float3 ShadowDepthBiasAndLightType;// Offset:  208 Size:    12 [unused]
//   float __padding11;                 // Offset:  220 Size:     4 [unused]
//   float4 SubframeViewport;           // Offset:  224 Size:    16 [unused]
//   row_major float3x4 DepthToWorld;   // Offset:  240 Size:    48
//   float4 DepthToView;                // Offset:  288 Size:    16
//   float4 OneOverDepthToView;         // Offset:  304 Size:    16 [unused]
//   float4 DepthToW;                   // Offset:  320 Size:    16 [unused]
//   float4 ClipPlane;                  // Offset:  336 Size:    16 [unused]
//   float2 ViewportDepthScaleOffset;   // Offset:  352 Size:     8 [unused]
//   float2 __padding1;                 // Offset:  360 Size:     8 [unused]
//   float2 ColorDOFDepthScaleOffset;   // Offset:  368 Size:     8 [unused]
//   float2 __padding2;                 // Offset:  376 Size:     8 [unused]
//   float4 TimeVector;                 // Offset:  384 Size:    16 [unused]
//   float4 FogParams2;                 // Offset:  400 Size:    16 [unused]
//   float4 FogParams3;                 // Offset:  416 Size:    16 [unused]
//   float3 GlobalAmbient;              // Offset:  432 Size:    12 [unused]
//   float __padding8;                  // Offset:  444 Size:     4 [unused]
//   float4 GlobalParams[16];           // Offset:  448 Size:   256 [unused]
//   float4 ViewToFogH;                 // Offset:  704 Size:    16 [unused]
//   float4 ScreenExtents;              // Offset:  720 Size:    16
//   float2 ScreenResolution;           // Offset:  736 Size:     8 [unused]
//   float2 __padding3;                 // Offset:  744 Size:     8 [unused]
//   float4 PSSMToMap1Lin;              // Offset:  752 Size:    16 [unused]
//   float4 PSSMToMap1Const;            // Offset:  768 Size:    16 [unused]
//   float4 PSSMToMap2Lin;              // Offset:  784 Size:    16 [unused]
//   float4 PSSMToMap2Const;            // Offset:  800 Size:    16 [unused]
//   float4 PSSMToMap3Lin;              // Offset:  816 Size:    16 [unused]
//   float4 PSSMToMap3Const;            // Offset:  832 Size:    16 [unused]
//   float4 PSSMDistances;              // Offset:  848 Size:    16 [unused]
//   row_major float4x4 WorldToPSSM0;   // Offset:  864 Size:    64 [unused]
//   row_major float4x4 PrevViewProject;// Offset:  928 Size:    64 [unused]
//   row_major float4x4 PrevWorld;      // Offset:  992 Size:    64 [unused]
//   row_major float4x4 ViewT;          // Offset: 1056 Size:    64 [unused]
//   float4 PSSMExtents;                // Offset: 1120 Size:    16 [unused]
//   float4 ShadowAtlasResolution;      // Offset: 1136 Size:    16 [unused]
//   float4 UnitRimData[3];             // Offset: 1152 Size:    48 [unused]
//   float3 __CameraPositionForCorrection;// Offset: 1200 Size:    12 [unused]
//   float __padding7;                  // Offset: 1212 Size:     4 [unused]
//   row_major float4x4 CameraViewProject;// Offset: 1216 Size:    64 [unused]
//   float4 BackBufferResolution;       // Offset: 1280 Size:    16 [unused]
//   row_major float4x4 InverseProjection;// Offset: 1296 Size:    64 [unused]
//   float4 StereoOffset;               // Offset: 1360 Size:    16 [unused]
//   row_major float4x4 Projection;     // Offset: 1376 Size:    64 [unused]
//   row_major float4x4 ViewInv;        // Offset: 1440 Size:    64 [unused]
//   float4 ColorSSAO;                  // Offset: 1504 Size:    16 [unused]
//   float4 GlobalFogColor;             // Offset: 1520 Size:    16 [unused]
//   float4 VolumetricLightGlobalParams;// Offset: 1536 Size:    16 [unused]
//   float4 SnowParams01;               // Offset: 1552 Size:    16 [unused]
//   float4 SnowParams02;               // Offset: 1568 Size:    16 [unused]
//   float4 SnowParams03;               // Offset: 1584 Size:    16 [unused]
//   int SSREnabled;                    // Offset: 1600 Size:     4 [unused]
//   int __padding4;                    // Offset: 1604 Size:     4 [unused]
//   int __padding5;                    // Offset: 1608 Size:     4 [unused]
//   int __padding6;                    // Offset: 1612 Size:     4 [unused]
//
// }
//
// cbuffer MaterialBuffer
// {
//
//   float4 MaterialParams[512];        // Offset:    0 Size:  8192
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// SamplerGenericTrilinearWrap       sampler      NA          NA   11        1
// p_default_Material_n214_n230_Texture_texture    texture  float4          2d    0        1
// p_default_Setup_n40_n59_Texture_texture    texture  float4          2d    1        1
// p_default_Setup_n16_n122_4DF3FB3016561432_cp3_Param_texture    texture  float4          2d    2        1
// p_default_Setup_n16_n73_Texture_texture    texture  float4          2d    3        1
// p_default_Setup_n19_n70_Texture_texture    texture  float4          2d    4        1
// p_default_Setup_n16_n117_Texture_texture    texture  float4          2d    5        1
// p_default_Setup_n19_n57_Texture_texture    texture  float4          2d    6        1
// p_default_Setup_n33_470EB2D06866788_cp8_Param_texture    texture  float4          2d    7        1
// p_default_Setup_n19_n59_Texture_texture    texture  float4          2d    8        1
// p_default_Setup_n33_n70_Texture_texture    texture  float4          2d    9        1
// p_default_Setup_n38_Texture_texture    texture  float4          2d   10        1
// p_default_Setup_n33_n59_Texture_texture    texture  float4          2d   11        1
// p_default_Setup_n6_n84_Texture_texture    texture  float4          2d   13        1
// p_default_Setup_n23_Texture_texture    texture  float4          2d   14        1
// p_default_Setup_n34_n59_Texture_texture    texture  float4          2d   15        1
// p_default_Setup_n6_n73_Texture_texture    texture  float4          2d   16        1
// p_default_Setup_n34_n70_Texture_texture    texture  float4          2d   17        1
// p_default_Setup_n34_470EB2D06866788_cp8_Param_texture    texture  float4          2d   18        1
// p_default_Setup_n6_471057409100914_cp8_Param_texture    texture  float4          2d   19        1
// p_default_Setup_n40_n70_Texture_texture    texture  float4          2d   20        1
// DrawableBuffer                    cbuffer      NA          NA    1        1
// SceneBuffer                       cbuffer      NA          NA    2        1
// MaterialBuffer                    cbuffer      NA          NA    3        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float   xy w
// COLOR                    1   xyzw        1     NONE   float    yzw
// TEXCOORD                 0   xyzw        2     NONE   float   xy  
// TEXCOORD                 1   xyzw        3     NONE   float     zw
// TEXCOORD                 2   xyz         4     NONE   float   xyz 
// PSIZE                    0   x           5     NONE    uint   x   
//
//
// 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 cb1[259], dynamicIndexed
// dcl_constantbuffer cb2[46], immediateIndexed
dcl_constantbuffer cb2[82], immediateIndexed
dcl_constantbuffer cb3[21], immediateIndexed
dcl_sampler s11, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_resource_texture2d (float,float,float,float) t1
dcl_resource_texture2d (float,float,float,float) t2
dcl_resource_texture2d (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_texture2d (float,float,float,float) t7
dcl_resource_texture2d (float,float,float,float) t8
dcl_resource_texture2d (float,float,float,float) t9
dcl_resource_texture2d (float,float,float,float) t10
dcl_resource_texture2d (float,float,float,float) t11
dcl_resource_texture2d (float,float,float,float) t13
dcl_resource_texture2d (float,float,float,float) t14
dcl_resource_texture2d (float,float,float,float) t15
dcl_resource_texture2d (float,float,float,float) t16
dcl_resource_texture2d (float,float,float,float) t17
dcl_resource_texture2d (float,float,float,float) t18
dcl_resource_texture2d (float,float,float,float) t19
dcl_resource_texture2d (float,float,float,float) t20
dcl_input_ps_siv linear noperspective v0.xyw, position
dcl_input_ps linear v1.yzw
dcl_input_ps linear v2.xy
dcl_input_ps linear v3.zw
dcl_input_ps linear v4.xyz
dcl_input_ps constant v5.x
dcl_output o0.xyzw
// dcl_temps 13
dcl_temps 15
dcl_resource_texture2d (float,float,float,float) t125
mov r0.xw, l(0,0,0,1.000000)
mov r1.xw, l(0,0,0,1.000000)
mad r2.xy, v0.xyxx, cb2[45].zwzz, cb2[45].xyxx
mul r3.xy, r2.xyxx, v0.wwww

//Screen space correction, therefore need the '0.5'
ld_indexable(texture2d)(float,float,float,float) r14.xyzw, l(0, 0, 0, 0), t125.xyzw
add r14.w, v0.w, -r14.y
mul r14.w, r14.w, r14.x
mul r14.w, r14.w, l(0.5)
//MANUALLY FIXED
// SCRIPT CORRECTION
add r3.x, r3.x, -r14.w


mad r2.xy, r2.xyxx, cb2[18].xyxx, cb2[18].zwzz
mul r2.xy, r2.xyxx, v0.wwww
mov r3.z, v0.w




mov r3.w, l(1.000000)
dp4 r4.x, cb2[15].xyzw, r3.xyzw
dp4 r4.y, cb2[16].xyzw, r3.xyzw
dp4 r4.z, cb2[17].xyzw, r3.xyzw
dp3 r2.w, r4.xyzx, l(0.333333343, 0.333333343, 0.333333343, 0.000000)
add r3.xyz, r2.wwww, r4.xyzx
round_ni r3.xyz, r3.xyzx
add r5.xyz, -r3.xyzx, r4.xyzx
dp3 r2.w, r3.xyzx, l(0.166666672, 0.166666672, 0.166666672, 0.000000)
add r5.xyz, r2.wwww, r5.xyzx
ge r6.xyz, r5.zxyz, r5.xyzx
and r7.xyz, r6.yzxy, l(0x3f800000, 0x3f800000, 0x3f800000, 0)
movc r6.xyz, r6.xyzx, l(0,0,0,0), l(1.000000,1.000000,1.000000,0)
min r8.xyz, r6.xyzx, r7.xyzx
max r6.xyz, r6.xyzx, r7.xyzx
mov r1.y, r8.z
mov r1.z, r6.z
mul r7.xyz, r3.xyzx, l(0.00346020772, 0.00346020772, 0.00346020772, 0.000000)
round_ni r7.xyz, r7.xyzx
mad r3.xyz, -r7.xyzx, l(289.000000, 289.000000, 289.000000, 0.000000), r3.xyzx
add r1.xyzw, r1.xyzw, r3.zzzz
mad r7.xyzw, r1.xyzw, l(34.000000, 34.000000, 34.000000, 34.000000), l(1.000000, 1.000000, 1.000000, 1.000000)
mul r1.xyzw, r1.xyzw, r7.xyzw
mul r7.xyzw, r1.xyzw, l(0.00346020772, 0.00346020772, 0.00346020772, 0.00346020772)
round_ni r7.xyzw, r7.xyzw
mad r1.xyzw, -r7.xyzw, l(289.000000, 289.000000, 289.000000, 289.000000), r1.xyzw
add r1.xyzw, r3.yyyy, r1.xyzw
mov r0.y, r8.y
mov r0.z, r6.y
add r0.xyzw, r0.xyzw, r1.xyzw
mad r1.xyzw, r0.xyzw, l(34.000000, 34.000000, 34.000000, 34.000000), l(1.000000, 1.000000, 1.000000, 1.000000)
mul r0.xyzw, r0.xyzw, r1.xyzw
mul r1.xyzw, r0.xyzw, l(0.00346020772, 0.00346020772, 0.00346020772, 0.00346020772)
round_ni r1.xyzw, r1.xyzw
mad r0.xyzw, -r1.xyzw, l(289.000000, 289.000000, 289.000000, 289.000000), r0.xyzw
add r0.xyzw, r3.xxxx, r0.xyzw
mov r1.xw, l(0,0,0,1.000000)
mov r1.y, r8.x
add r3.xyz, r5.xyzx, -r8.xyzx
add r3.xyz, r3.xyzx, l(0.166666672, 0.166666672, 0.166666672, 0.000000)
mov r1.z, r6.x
add r6.xyz, r5.xyzx, -r6.xyzx
add r6.xyz, r6.xyzx, l(0.333333343, 0.333333343, 0.333333343, 0.000000)
add r0.xyzw, r0.xyzw, r1.xyzw
mad r1.xyzw, r0.xyzw, l(34.000000, 34.000000, 34.000000, 34.000000), l(1.000000, 1.000000, 1.000000, 1.000000)
mul r0.xyzw, r0.xyzw, r1.xyzw
mul r1.xyzw, r0.xyzw, l(0.00346020772, 0.00346020772, 0.00346020772, 0.00346020772)
round_ni r1.xyzw, r1.xyzw
mad r0.xyzw, -r1.xyzw, l(289.000000, 289.000000, 289.000000, 289.000000), r0.xyzw
mul r1.xyzw, r0.xyzw, l(0.0204081647, 0.0204081647, 0.0204081647, 0.0204081647)
round_ni r1.xyzw, r1.xyzw
mad r0.xyzw, -r1.xyzw, l(49.000000, 49.000000, 49.000000, 49.000000), r0.xyzw
mul r1.xyzw, r0.xyzw, l(0.142857149, 0.142857149, 0.142857149, 0.142857149)
round_ni r1.xyzw, r1.xyzw
mad r0.xyzw, -r1.xyzw, l(7.000000, 7.000000, 7.000000, 7.000000), r0.xyzw
mad r1.xyzw, r1.zxwy, l(0.285714298, 0.285714298, 0.285714298, 0.285714298), l(-0.928571403, -0.928571403, -0.928571403, -0.928571403)
mad r0.xyzw, r0.xyzw, l(0.285714298, 0.285714298, 0.285714298, 0.285714298), l(-0.928571403, -0.928571403, -0.928571403, -0.928571403)
mov r7.yw, r0.xxxy
mov r7.xz, r1.yywy
round_ni r8.yw, r0.xxxy
round_ni r8.xz, r1.yywy
mad r8.xyzw, r8.xyzw, l(2.000000, 2.000000, 2.000000, 2.000000), l(1.000000, 1.000000, 1.000000, 1.000000)
add r9.xyzw, -|r1.ywxz|, l(1.000000, 1.000000, 1.000000, 1.000000)
add r9.xyzw, -|r0.xywz|, r9.xywz
ge r10.xyzw, l(0.000000, 0.000000, 0.000000, 0.000000), r9.xywz
movc r10.xyzw, r10.xyzw, l(-1.000000,-1.000000,-1.000000,-1.000000), l(-0.000000,-0.000000,-0.000000,-0.000000)
mad r7.xyzw, r8.zwxy, r10.yyxx, r7.zwxy
mov r8.xy, r7.zwzz
mov r8.z, r9.x
dp3 r11.x, r8.xyzx, r8.xyzx
mov r7.z, r9.y
dp3 r11.y, r7.xyzx, r7.xyzx
round_ni r12.yw, r0.zzzw
mov r1.yw, r0.zzzw
round_ni r12.xz, r1.xxzx
mad r0.xyzw, r12.xyzw, l(2.000000, 2.000000, 2.000000, 2.000000), l(1.000000, 1.000000, 1.000000, 1.000000)
mad r0.xyzw, r0.xyzw, r10.zzww, r1.xyzw
mov r9.xy, r0.zwzz
mov r0.z, r9.w
dp3 r11.z, r0.xyzx, r0.xyzx
dp3 r11.w, r9.xyzx, r9.xyzx
mad r1.xyzw, -r11.xyzw, l(0.853734732, 0.853734732, 0.853734732, 0.853734732), l(1.79284286, 1.79284286, 1.79284286, 1.79284286)
mul r7.xyz, r1.yyyy, r7.xyzx
dp3 r7.y, r7.xyzx, r3.xyzx
dp3 r3.y, r3.xyzx, r3.xyzx
mul r0.xyz, r0.xyzx, r1.zzzz
dp3 r7.z, r0.xyzx, r6.xyzx
dp3 r3.z, r6.xyzx, r6.xyzx
mul r0.xyz, r1.xxxx, r8.xyzx
mul r1.xyz, r1.wwww, r9.xyzx
dp3 r7.x, r0.xyzx, r5.xyzx
add r0.xyz, r5.xyzx, l(-0.500000, -0.500000, -0.500000, 0.000000)
dp3 r3.x, r5.xyzx, r5.xyzx
dp3 r7.w, r1.xyzx, r0.xyzx
dp3 r3.w, r0.xyzx, r0.xyzx
add r0.xyzw, -r3.xyzw, l(0.600000, 0.600000, 0.600000, 0.600000)
max r0.xyzw, r0.xyzw, l(0.000000, 0.000000, 0.000000, 0.000000)
mul r0.xyzw, r0.xyzw, r0.xyzw
mul r0.xyzw, r0.xyzw, r0.xyzw
dp4 r0.x, r0.xyzw, r7.xyzw
mul r0.x, r0.x, cb3[20].y
mad r0.x, r0.x, l(42.000000), v3.w
ge r0.x, v3.z, r0.x
and r0.x, r0.x, l(0x3f800000)
mul r1.xyzw, v2.xyxy, cb3[7].zwxy
sample_indexable(texture2d)(float,float,float,float) r0.y, r1.xyxx, t6.xwyz, s11
sample_indexable(texture2d)(float,float,float,float) r0.zw, r1.zwzz, t17.zwxy, s11
mad r0.zw, r0.zzzw, l(0.000000, 0.000000, 2.000000, 2.000000), l(0.000000, 0.000000, -1.000000, -1.000000)
mul r0.y, r0.y, cb3[0].w
max r0.y, r0.y, l(0.000000)
mad r0.x, r0.y, r0.x, -cb1[2].x
mul r1.xy, v0.xyxx, l(0.250000, 0.250000, 0.000000, 0.000000)
sample_indexable(texture2d)(float,float,float,float) r0.y, r1.xyxx, t0.yxzw, s11
mov r1.x, v5.x
mad r0.y, r0.y, cb1[r1.x + 3].y, cb1[r1.x + 3].z
min r0.x, r0.y, r0.x
lt r0.x, r0.x, l(0.000000)
discard_nz r0.x
deriv_rty_fine r1.xy, v2.xyxx
deriv_rtx_fine r0.xy, v2.xyxx
mul r1.x, r1.x, r0.y
mad r0.x, r0.x, r1.y, -r1.x
mov r1.z, -r0.y
lt r0.y, r0.x, l(0.000000)
lt r0.x, l(0.000000), |r0.x|
movc r0.y, r0.y, l(-1.000000), l(1.000000)
mul r1.xy, r1.yzyy, r0.yyyy
deriv_rty_fine r3.xyz, r4.xyzx
deriv_rtx_fine r4.xyz, r4.yzxy
dp3 r1.z, v4.xyzx, v4.xyzx
rsq r1.z, r1.z
mul r5.xyz, r1.zzzz, v4.xyzx
dp3 r1.w, r3.xyzx, r5.xyzx
mad r3.xyz, -r1.wwww, r5.xyzx, r3.xyzx
mul r6.xyz, r1.yyyy, r3.xyzx
dp3 r1.y, r4.zxyz, r5.xyzx
mad r4.xyz, -r1.yyyy, r5.yzxy, r4.xyzx
mad r1.xyw, r4.zxzy, r1.xxxx, r6.xyxz
dp3 r2.w, r1.xywx, r1.xywx
rsq r2.w, r2.w
mul r6.xyz, r1.xywx, r2.wwww
movc r1.xyw, r0.xxxx, r6.xyxz, r1.xyxw
mul r6.xyz, r1.ywxy, r5.zxyz
mad r6.xyz, r5.yzxy, r1.wxyw, -r6.xyzx
mul r7.xyz, r4.xyzx, r5.zxyz
mad r4.xyz, r5.yzxy, r4.yzxy, -r7.xyzx
dp3 r0.x, r3.xyzx, r4.xyzx
lt r0.x, r0.x, l(0.000000)
movc r0.x, r0.x, l(-1.000000), l(1.000000)
mul r0.x, r0.x, r0.y
mul r3.xyz, r0.xxxx, r6.xyzx
mad r0.x, -r0.z, r0.z, l(1.000000)
mad r0.x, -r0.w, r0.w, r0.x
mul r4.xy, r0.zwzz, r0.zwzz
max r0.y, r4.y, r4.x
mul r0.y, r0.y, l(0.0000610351563)
max r0.x, r0.y, r0.x
rsq r0.x, r0.x
mul r0.xy, r0.zwzz, -r0.xxxx
mul r0.xy, r0.xyxx, cb3[17].zzzz
mul r4.xyzw, v2.xyxy, cb3[6].xyzw
sample_indexable(texture2d)(float,float,float,float) r0.zw, r4.zwzz, t9.zwxy, s11
sample_indexable(texture2d)(float,float,float,float) r4.xyz, r4.xyxx, t10.xyzw, s11
mad r0.zw, r0.zzzw, l(0.000000, 0.000000, 2.000000, 2.000000), l(0.000000, 0.000000, -1.000000, -1.000000)
mad r2.w, -r0.z, r0.z, l(1.000000)
mad r2.w, -r0.w, r0.w, r2.w
mul r6.xy, r0.zwzz, r0.zwzz
max r3.w, r6.y, r6.x
mul r3.w, r3.w, l(0.0000610351563)
max r2.w, r2.w, r3.w
rsq r2.w, r2.w
mul r0.zw, r0.zzzw, -r2.wwww
mul r0.zw, r0.zzzw, cb3[14].wwww
mul r6.xyzw, v2.xyxy, cb3[12].xyzw
sample_indexable(texture2d)(float,float,float,float) r6.zw, r6.zwzz, t20.zwxy, s11
sample_indexable(texture2d)(float,float,float,float) r2.w, r6.xyxx, t8.xzwy, s11
mad r6.xy, r6.zwzz, l(2.000000, 2.000000, 0.000000, 0.000000), l(-1.000000, -1.000000, 0.000000, 0.000000)
mad r3.w, -r6.x, r6.x, l(1.000000)
mad r3.w, -r6.y, r6.y, r3.w
mul r6.zw, r6.xxxy, r6.xxxy
max r4.w, r6.w, r6.z
mul r4.w, r4.w, l(0.0000610351563)
max r3.w, r3.w, r4.w
rsq r3.w, r3.w
mul r6.xy, r6.xyxx, -r3.wwww
mul r6.xy, r6.xyxx, cb3[3].wwww
mul r7.xyzw, v2.xyxy, cb3[9].zwxy
sample_indexable(texture2d)(float,float,float,float) r6.zw, r7.xyxx, t3.zwxy, s11
sample_indexable(texture2d)(float,float,float,float) r3.w, r7.zwzz, t15.xzwy, s11
mad r6.zw, r6.zzzw, l(0.000000, 0.000000, 2.000000, 2.000000), l(0.000000, 0.000000, -1.000000, -1.000000)
mad r4.w, -r6.z, r6.z, l(1.000000)
mad r4.w, -r6.w, r6.w, r4.w
mul r7.xy, r6.zwzz, r6.zwzz
max r5.w, r7.y, r7.x
mul r5.w, r5.w, l(0.0000610351563)
max r4.w, r4.w, r5.w
rsq r4.w, r4.w
mul r6.zw, r6.zzzw, -r4.wwww
mul r7.xyzw, v2.xyxy, cb3[8].xyzw
sample_indexable(texture2d)(float,float,float,float) r7.xy, r7.xyxx, t4.xyzw, s11
sample_indexable(texture2d)(float,float,float,float) r4.w, r7.zwzz, t5.xzwy, s11
mad r7.xy, r7.xyxx, l(2.000000, 2.000000, 0.000000, 0.000000), l(-1.000000, -1.000000, 0.000000, 0.000000)
mad r5.w, -r7.x, r7.x, l(1.000000)
mad r5.w, -r7.y, r7.y, r5.w
mul r7.zw, r7.xxxy, r7.xxxy
max r7.z, r7.w, r7.z
mul r7.z, r7.z, l(0.0000610351563)
max r5.w, r5.w, r7.z
rsq r5.w, r5.w
mul r7.xy, r7.xyxx, -r5.wwww
mul r8.xyzw, v2.xyxy, cb3[5].xyzw
sample_indexable(texture2d)(float,float,float,float) r7.zw, r8.xyxx, t16.zwxy, s11
sample_indexable(texture2d)(float,float,float,float) r5.w, r8.zwzz, t11.xzwy, s11
mad r7.zw, r7.zzzw, l(0.000000, 0.000000, 2.000000, 2.000000), l(0.000000, 0.000000, -1.000000, -1.000000)
mad r8.x, -r7.z, r7.z, l(1.000000)
mad r8.x, -r7.w, r7.w, r8.x
mul r8.yz, r7.zzwz, r7.zzwz
max r8.y, r8.z, r8.y
mul r8.y, r8.y, l(0.0000610351563)
max r8.x, r8.y, r8.x
rsq r8.x, r8.x
mul r7.zw, r7.zzzw, -r8.xxxx
mul r7.zw, r7.zzzw, cb3[18].wwww
mul r8.xyzw, v2.xyxy, cb3[10].xyzw
sample_indexable(texture2d)(float,float,float,float) r9.y, r8.xyxx, t19.yxzw, s11
sample_indexable(texture2d)(float,float,float,float) r8.x, r8.zwzz, t2.xyzw, s11
mul r8.x, r8.x, cb3[14].x
mov r9.z, l(1.000000)
sample_indexable(texture2d)(float,float,float,float) r8.yz, v2.xyxx, t14.xyzw, s11
mad r8.y, r8.y, cb3[18].y, cb3[18].z
mad r8.z, r8.z, cb3[16].z, cb3[16].y
mov_sat r10.xyz, v1.yzwy
mul_sat r9.x, r8.y, r10.x
dp3_sat r8.y, cb3[3].xyzx, r9.xyzx
mul r7.zw, r7.zzzw, r8.yyyy
mad r7.xy, r7.xyxx, cb3[19].zzzz, r7.zwzz
mad r6.zw, cb3[15].wwww, r6.zzzw, -r7.xxxy
mul_sat r7.z, r8.z, r10.y
mad r6.zw, r7.zzzz, r6.zzzw, r7.xxxy
add r7.x, r7.z, r8.y
min r7.x, r7.x, l(1.000000)
add r7.x, -r7.x, l(1.000000)
mul r4.xyz, r4.xyzx, r7.xxxx
mad_sat r4.x, r4.x, cb3[2].w, cb3[1].w
mad r6.xy, r6.xyxx, r4.xxxx, r6.zwzz
mad_sat r9.x, r4.y, cb3[15].y, cb3[15].x
mad_sat r11.x, r4.z, cb3[18].x, cb3[17].w
mul r12.xyzw, v2.xyxy, cb3[11].zwxy
sample_indexable(texture2d)(float,float,float,float) r9.y, r12.zwzz, t7.yxzw, s11
sample_indexable(texture2d)(float,float,float,float) r4.y, r12.xyxx, t1.xyzw, s11
mov r9.z, l(1.000000)
dp3_sat r4.z, cb3[2].xyzx, r9.xyzx
mad r0.zw, r0.zzzw, r4.zzzz, r6.xxxy
mul r6.xy, v2.xyxx, cb3[13].xyxx
sample_indexable(texture2d)(float,float,float,float) r11.y, r6.xyxx, t18.yxzw, s11
mov r11.z, l(1.000000)
dp3_sat r6.x, cb3[1].xyzx, r11.xyzx
mad r0.xy, r0.xyxx, r6.xxxx, r0.zwzz
mul r0.yzw, r3.xxyz, r0.yyyy
mad r0.xyz, r0.xxxx, r1.xywx, r0.yzwy
mad r0.xyz, v4.xyzx, r1.zzzz, -r0.xyzx
dp3 r0.w, r0.xyzx, r0.xyzx
rsq r0.w, r0.w
mul o0.xyz, r0.wwww, r0.xyzx
mov r2.z, v0.w
dp3 r0.x, -r2.xyzx, -r2.xyzx
rsq r0.x, r0.x
mul r0.xyz, r0.xxxx, -r2.xyzx
dp3 r1.z, r0.xyzx, cb2[2].xyzx
dp3 r1.x, r0.xyzx, cb2[0].xyzx
dp3 r1.y, r0.xyzx, cb2[1].xyzx
dp3 r0.x, -r1.xyzx, r5.xyzx
add r0.x, r0.x, r0.x
mad r0.xy, r5.xyxx, -r0.xxxx, -r1.xyxx
mul r0.xy, r0.xyxx, cb3[15].zzzz
sample_indexable(texture2d)(float,float,float,float) r0.x, r0.xyxx, t2.yxzw, s11
mul_sat r0.x, r8.x, r0.x
add r0.y, -cb3[16].w, cb3[16].x
mad r0.y, r4.w, r0.y, cb3[16].w
add r0.z, -r0.y, l(1.000000)
mad r0.x, r0.x, r0.z, r0.y
add r0.y, cb3[19].w, -cb3[20].z
mad r0.y, r2.w, r0.y, cb3[20].z
mul r0.zw, v2.xxxy, cb3[4].xxxy
sample_indexable(texture2d)(float,float,float,float) r0.z, r0.zwzz, t13.xzyw, s11
add r0.w, -cb3[19].y, cb3[19].x
mad r0.z, r0.z, r0.w, cb3[19].y
add r0.z, -r0.y, r0.z
mad r0.y, r8.y, r0.z, r0.y
add r0.x, -r0.y, r0.x
mad r0.x, r7.z, r0.x, r0.y
add r0.y, -cb3[13].w, cb3[13].z
mad r0.y, r4.y, r0.y, cb3[13].w
add r0.y, -r0.x, r0.y
mad r0.x, r4.x, r0.y, r0.x
add r0.y, -cb3[14].y, cb3[14].z
mad r0.y, r5.w, r0.y, cb3[14].y
add r0.y, -r0.x, r0.y
mad r0.x, r4.z, r0.y, r0.x
add r0.y, -cb3[17].x, cb3[17].y
mad r0.y, r3.w, r0.y, cb3[17].x
add r0.y, -r0.x, r0.y
mad r0.x, r6.x, r0.y, r0.x
mad r0.y, r0.x, cb3[20].x, -r0.x
mad r0.x, r10.z, r0.y, r0.x
max r0.x, r0.x, l(2.000000)
log r0.x, r0.x
add r0.x, r0.x, l(-1.000000)
mul r0.x, r0.x, l(0.0833333358)
min o0.w, r0.x, l(1.000000)
ret 
// Approximately 318 instruction slots used
