// Light Shafts (DSS)
// Generated by Microsoft (R) HLSL Shader Compiler 10.0.10011.16384
//
//   using 3Dmigoto v1.3.11 on Tue Mar 05 19:41:32 2019
//
//
// Buffer Definitions:
//
// cbuffer _cbSharedPerViewData
// {
//
//   struct S_cbSharedPerViewData
//   {
//
//       row_major float4x4 mProjection;// Offset:    0
//       row_major float4x4 mProjectionPrev;// Offset:   64
//       row_major float4x4 mViewToViewport;// Offset:  128
//       row_major float4x4 mViewToWorld;// Offset:  192
//       row_major float4x4 mViewToWorldPrev;// Offset:  256
//       row_major float4x4 mFxWorldToSampleSpace;// Offset:  320
//       float4 vViewRemap;             // Offset:  384
//       float4 vViewDepthRemap;        // Offset:  400
//       float4 vEyeVectorUL;           // Offset:  416
//       float4 vEyeVectorLR;           // Offset:  432
//       float4 vEyeVectorDelta;        // Offset:  448
//       float4 vPixelToEyeVectorScaleBias;// Offset:  464
//       float4 vViewSpaceUpVector;     // Offset:  480
//       float4 vViewportSize;          // Offset:  496
//       float4 vTesselationEnabled;    // Offset:  512
//       float4 vEngineTime;            // Offset:  528
//       uint nFrameCounter;            // Offset:  544
//       float4 vShaderColor0;          // Offset:  560
//       float4 vShaderColor1;          // Offset:  576
//       float4 vShaderColor2;          // Offset:  592
//       float4 vShaderColor3;          // Offset:  608
//       float4 vShaderColor4;          // Offset:  624
//       float4 vClipPlane;             // Offset:  640
//       float4 vClipPlane0;            // Offset:  656
//       float4 vClipPlane1;            // Offset:  672
//       float4 vClipPlane2;            // Offset:  688
//       float4 vClipPlane3;            // Offset:  704
//       float4 vClipPlane4;            // Offset:  720
//       float4 vClipPlane5;            // Offset:  736
//       float4 vMippedDepthRemap;      // Offset:  752
//       float4 vSpecularOcclusionSettings;// Offset:  768
//       float4 vSaturatedAmbientOcclusionSettings;// Offset:  784
//       float4 vLightModelSettings;    // Offset:  800
//       float4 vHDRScale;              // Offset:  816
//       float4 vTweakableShaderParams; // Offset:  832
//       float4 vAtmosphericScatteringParameters;// Offset:  848
//       float4 vAtmosphericScatteringParameters2;// Offset:  864
//       float4 vAtmosphericScatteringParameters3;// Offset:  880
//       float3 vAtmosphericScatteringMieBeta;// Offset:  896
//       float3 vAtmosphericScatteringRayleighBeta;// Offset:  912
//       float3 vAtmosphericScatteringShadowedMieBeta;// Offset:  928
//       float3 vAtmosphericScatteringShadowedRayleighBeta;// Offset:  944
//       float3 vAttenuatedSunColor;    // Offset:  960
//       float3 vSunDirectionVS;        // Offset:  976
//       row_major float4x4 mViewToGlobalShadowVSPT;// Offset:  992
//       float4 vWindDirectionAndStrength;// Offset: 1056
//       float4 vWindDirectionAndStrengthPrev;// Offset: 1072
//       float4 vWindInitialDirectionAndStrength;// Offset: 1088
//       float4 vFxFadeParameters;      // Offset: 1104
//       float2 vFxSize;                // Offset: 1120
//       int nEnableGBufferSpecPowerAdjustment;// Offset: 1128
//       int nNumCSMCascades;           // Offset: 1132
//       float fCSMFadeAdd;             // Offset: 1136
//       int nEnableClothBias;          // Offset: 1140
//       int nEnableCloth;              // Offset: 1144
//       int2 viNumTiles;               // Offset: 1152
//       int nLightTileDebugFlags;      // Offset: 1160
//       int nEnableBoxReflections;     // Offset: 1164
//       int nSelectedBoxReflectionId;  // Offset: 1168
//       int nEnableAtmosphericScatteringBackdrop;// Offset: 1172
//       int nEnableSampleFromUICameraBackbuffer;// Offset: 1176
//       int nFallbackRoomMask;         // Offset: 1180
//       float4 vClearColor;            // Offset: 1184
//       float3 vGlobalLightDirectionVS;// Offset: 1200
//       float3 vGlobalLightFrontColor; // Offset: 1216
//       float3 vGlobalLightBackColor;  // Offset: 1232
//       float4 vShadowAtlasSize;       // Offset: 1248
//       float2 vShadowPoissonScale;    // Offset: 1264
//       int nShadowSpotKernel;         // Offset: 1272
//       int nShadowCSMKernel;          // Offset: 1276
//       float4 vJitter;                // Offset: 1280
//       float4 vUnjitter;              // Offset: 1296
//       int nHashedAlphaPeriod;        // Offset: 1312
//       int nIsRenderingOffscreen;     // Offset: 1316
//       int nMirrorsDisabled;          // Offset: 1320
//
//   } cbSharedPerViewData;             // Offset:    0 Size:  1324
//
// }
//
// cbuffer _cbCalculateEpipolarInscatter
// {
//
//   struct S_cbCalculateEpipolarInscatter
//   {
//
//       int nNumCSMCascades;           // Offset:    0
//       float fDitherOffset;           // Offset:    4
//       float fCSMFadeAdd;             // Offset:    8
//       float4 vSignedFullResToUnsignedHalfRes;// Offset:   16
//       float4 vRow0;                  // Offset:   32
//       float4 vRow1;                  // Offset:   48
//       float4 vRow2;                  // Offset:   64
//       float4 vBleedReduction;        // Offset:   80
//       float4 avParams[9];            // Offset:   96
//       float3 vSunColor;              // Offset:  240
//       float3 vSunDirWS;              // Offset:  256
//       float3 vSunDirVS;              // Offset:  272
//       float2 vSunUVPos;              // Offset:  288
//       float2 vUVClampingUpper;       // Offset:  296
//       row_major float4x4 mViewToWorld;// Offset:  304
//       row_major float4x4 mViewToPrevViewProj;// Offset:  368
//       int2 viHalfRes;                // Offset:  432
//       float2 vRcpHalfRes;            // Offset:  440
//       int2 viHalfResRT;              // Offset:  448
//       float2 vRcpHalfResRT;          // Offset:  456
//
//   } cbCalculateEpipolarInscatter;    // Offset:    0 Size:   464
//
// }
//
// Resource bind info for srvWorkItems
// {
//
//   uint $Element;                     // Offset:    0 Size:     4
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// samplerPointClamp                 sampler      NA          NA    0        1
// samplerPointClampWrap             sampler      NA          NA   14        1
// srvDepthBuffer                    texture  float4          2d    0        1
// srvWorkItemsCounter               texture    uint         buf    1        1
// srvWorkItems                      texture  struct         r/o    2        1
// srvShadowTexture                  texture  float4          2d    3        1
// srvGlobalShadow                   texture  float4          2d   25        1
// uavFillHolesOutputTexture             UAV  float4          2d    0        1
// _cbSharedPerViewData              cbuffer      NA          NA    2        1
// _cbCalculateEpipolarInscatter     cbuffer      NA          NA    5        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// no Input
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// no Output
cs_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer cb2[60], immediateIndexed
dcl_constantbuffer cb5[23], immediateIndexed
dcl_sampler s0, mode_default
dcl_sampler s14, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_resource_buffer (uint,uint,uint,uint) t1
dcl_resource_structured t2, 4
dcl_resource_texture2d (float,float,float,float) t3
dcl_resource_texture2d (float,float,float,float) t25
dcl_uav_typed_texture2d (float,float,float,float) u0
dcl_input vThreadID.x
//dcl_temps 14
dcl_temps 17


dcl_thread_group 64, 1, 1

dcl_resource_texture2d (float,float,float,float) t125

// Correct cbCalculateEpipolarInscatter.vSunUVPos.xy -DarkStarSword
ld_indexable(texture2d)(float,float,float,float) r15.xyzw, l(0, 0, 0, 0), t125.xyzw
mov r16.xyzw, cb5[18].xyxx
mad r16.x, r15.x, l(0.5), r16.x

ld_indexable(buffer)(uint,uint,uint,uint) r0.x, l(0, 0, 0, 0), t1.xyzw
uge r0.x, vThreadID.x, r0.x
if_nz r0.x
  ret
endif
ld_structured_indexable(structured_buffer, stride=4)(mixed,mixed,mixed,mixed) r0.x, vThreadID.x, l(0), t2.xxxx
and r1.x, r0.x, l(0x0000ffff)
ushr r1.yzw, r0.xxxx, l(0, 16, 16, 16)
ishl r0.xy, r1.xwxx, l(1, 1, 0, 0)
utof r0.xy, r0.xyxx
add r0.xy, r0.xyxx, l(0.500000, 0.500000, 0.000000, 0.000000)
mul r2.xy, r0.xyxx, cb2[31].xyxx
mad r0.zw, r0.yyyx, cb2[31].yyyx, -r16.yyyx
lt r3.xy, l(0.000000, 0.000000, 0.000000, 0.000000), r0.wzww
and r3.xy, r3.xyxx, l(0x3f800000, 0x3f800000, 0, 0)
add r3.zw, r3.xxxy, -r16.xxxy
div r3.zw, r3.zzzw, r0.wwwz
lt r2.w, r3.z, r3.w
mad_sat r0.zw, r3.zzzw, r0.zzzw, r16.yyyx
add r3.z, -r0.z, l(4.000000)
mad r0.z, r0.z, l(2.000000), l(-3.000000)
mad r0.z, r0.z, r3.x, r3.z
mad r3.x, -r0.w, l(2.000000), l(3.000000)
mad r0.w, r3.x, r3.y, r0.w
mul r0.zw, r0.zzzw, l(0.000000, 0.000000, 128.000000, 128.000000)
movc r0.z, r2.w, r0.z, r0.w
add r0.z, r0.z, l(0.500000)
sample_l_indexable(texture2d)(float,float,float,float) r0.w, r2.xyxx, t0.yzwx, s0, l(0.000000)
mad r2.w, cb2[24].z, r0.w, -cb2[24].y
div r2.w, l(1.000000, 1.000000, 1.000000, 1.000000), r2.w
add r3.xyz, -cb2[26].xyzx, cb2[27].xyzx
mov r2.z, l(1.000000)
mad r2.xyz, r2.xyzx, r3.xyzx, cb2[26].xyzx
dp3 r3.w, r2.xyzx, r2.xyzx
rsq r3.w, r3.w
mul r4.xyz, r2.xyzx, r3.wwww
mul r3.w, cb2[55].y, l(12.000000)
mul r5.xyz, r4.yyyy, cb2[13].xyzx
mad r5.xyz, r4.xxxx, cb2[12].xyzx, r5.xyzx
mad r5.xyz, r4.zzzz, cb2[14].xyzx, r5.xyzx
dp3 r4.w, cb5[16].xyzx, r5.xyzx
lt r5.w, r4.w, l(-0.900000)
add r6.x, |r4.w|, l(-0.900000)
mul r6.x, r6.x, l(10.000000)
and r5.w, r5.w, r6.x
lt r0.w, l(0.000000), r0.w
mul r6.yzw, r2.wwww, r2.xxyz
mul r7.x, r2.y, cb2[13].z
mad r7.x, r2.x, cb2[12].z, r7.x
mad r7.x, r2.z, cb2[14].z, r7.x
add r7.y, -cb2[15].z, cb2[53].y
div r7.x, r7.y, r7.x
lt r7.y, l(0.000000), r7.x
not r8.x, r7.y
min r7.x, r7.x, l(4000.000000)
movc r7.x, r7.y, r7.x, l(50000.000000)
mul r8.yzw, r4.xxyz, r7.xxxx
mov r6.x, l(0)
movc r6.xyzw, r0.wwww, r6.xyzw, r8.xyzw
round_z r0.z, r0.z
mad r7.xy, r0.zzzz, l(0.00781250000, 0.00781250000, 0.000000, 0.000000), l(-1.500000, -2.500000, 0.000000, 0.000000)
add_sat r7.xy, -|r7.xyxx|, l(1.500000, 1.500000, 0.000000, 0.000000)
mov r7.z, l(1.000000)
mad r3.xyz, r7.xyzx, r3.xyzx, cb2[26].xyzx
dp3 r0.w, r3.xyzx, cb5[17].xyzx
mad r3.xyz, -r0.wwww, cb5[17].xyzx, r3.xyzx
dp3 r0.w, r3.xyzx, r3.xyzx
rsq r0.w, r0.w
mul r3.xyz, r0.wwww, r3.xyzx
add r0.w, cb2[53].x, cb5[22].z
mov r7.xy, cb5[22].xyxx
add r7.z, r0.w, l(6360000.000000)
mad r7.w, r4.w, r4.w, l(1.000000)
mul r8.x, r7.w, l(0.0596831031)
mad r8.yz, cb2[54].xxxx, cb2[54].xxxx, l(0.000000, 1.000010, 2.000000, 0.000000)
dp2 r4.w, r4.wwww, cb2[54].xxxx
add r4.w, -r4.w, r8.y
mad r8.y, -cb2[54].x, cb2[54].x, l(1.000000)
mul r8.y, r7.w, r8.y
mul r8.y, r8.y, l(0.119366206)
mul r8.z, r4.w, r8.z
sqrt r4.w, r4.w
mul r4.w, r4.w, r8.z
div r4.w, r8.y, r4.w
mad r7.w, -r7.w, l(0.0596831031), l(0.0795774683)
mad r7.w, cb2[54].w, r7.w, r8.x
add r8.x, -r4.w, l(0.0795774683)
mad r4.w, cb2[54].w, r8.x, r4.w
mad r0.xy, r0.xyxx, cb2[31].xyxx, cb5[0].yyyy
dp2 r0.x, r0.xyxx, l(12.989800, 78.233002, 0.000000, 0.000000)
sincos r0.x, null, r0.x
mul r0.x, r0.x, l(43758.546875)
frc r0.x, r0.x
dp3 r0.y, r6.yzwy, r6.yzwy
rsq r8.x, r0.y
mul r6.yzw, r6.yyzw, r8.xxxx
sqrt r0.y, r0.y
mul r8.x, r0.y, l(0.800000)
min r8.y, r8.x, cb2[55].x
mul r9.xyz, r6.yzwy, r8.yyyy
dp3 r6.y, r7.xyzx, r5.xyzx
dp3 r6.z, r7.xyzx, r7.xyzx
add r6.z, r6.z, l(-41473600913408.000000)
mad r6.w, r6.y, r6.y, -r6.z
sqrt r6.w, r6.w
add r6.y, r6.w, -r6.y
mul r6.w, r8.y, cb2[55].z
min r8.z, r6.y, r6.w
mov r9.w, l(1.000000)
dp4 r8.w, cb5[4].xyzw, r9.xyzw
add r8.w, r8.w, -cb5[4].w
dp3 r9.x, r7.xyzx, cb5[16].xyzx
mad r6.z, r9.x, r9.x, -r6.z
sqrt r6.z, r6.z
add r6.z, r6.z, -r9.x
mul r9.x, r6.z, cb5[16].z
mul r9.yz, r9.xxxx, -cb2[53].wwzw
mul r10.xy, r0.wwww, -cb2[53].wzww
mad r9.xw, r9.xxxx, -cb2[53].wwwz, r10.xxxy
exp r9.xw, r9.xxxw
exp r10.xy, r10.xyxx
add r9.xw, r9.xxxw, -r10.xxxy
mul r9.yz, r9.yyzy, l(0.000000, 0.693147182, 0.693147182, 0.000000)
div r9.yz, r6.zzzz, r9.yyzy
mul r9.xy, r9.yzyy, r9.xwxx
mul r6.z, r0.x, l(0.015625)
mad r9.z, r6.z, r8.w, cb5[4].w
mul r8.w, r8.w, l(0.015625)
dp3 r2.x, r2.xyzx, r3.xyzx
mul r2.x, r8.y, r2.x
div r2.x, r2.x, cb2[55].x
mul r2.y, r2.x, r6.z
mul r2.x, r2.x, l(0.015625)
add r2.z, r2.w, l(-50.000000)
mul_sat r2.z, r2.z, l(0.010000)
lt r3.x, l(0.000000), r5.w
mul r2.z, r2.z, l(64.000000)
movc r2.z, r3.x, r2.z, l(64.000000)
add r0.z, r0.z, l(0.500000)
mul r10.w, r0.z, l(0.00195312500)
mov r3.y, r10.w
mov r0.z, l(0)
mov r3.z, l(0)
loop
  ige r6.z, r3.z, l(64)
  breakc_nz r6.z
  itof r6.z, r3.z
  mad_sat r9.w, r2.x, r6.z, r2.y
  iadd r11.xy, r3.zzzz, l(1, 3, 0, 0)
  iadd r11.z, r3.z, l(2)
  itof r11.xyz, r11.xyzx
  mad_sat r11.w, r2.x, r11.z, r2.y
  mad_sat r12.xy, r2.xxxx, r11.xyxx, r2.yyyy
  ishr r9.w, r9.w, l(1)
  iadd r10.z, r9.w, l(0x1fbd1df5)
  ishr r12.xy, r12.xyxx, l(1, 1, 0, 0)
  iadd r10.xy, r12.xyxx, l(0x1fbd1df5, 0x1fbd1df5, 0, 0)
  ishr r9.w, r11.w, l(1)
  iadd r3.x, r9.w, l(0x1fbd1df5)
  mov_sat r3.x, r3.x
  mov_sat r10.xyz, r10.xyzx
  sample_l_indexable(texture2d)(float,float,float,float) r9.w, r10.zwzz, t3.yzwx, s14, l(0.000000)
  mad r6.z, r8.w, r6.z, r9.z
  lt r6.z, r9.w, r6.z
  and r6.z, r6.z, l(0x3f800000)
  sample_l_indexable(texture2d)(float,float,float,float) r9.w, r10.xwxx, t3.yzwx, s14, l(0.000000)
  mad r10.xz, r8.wwww, r11.xxyx, r9.zzzz
  lt r9.w, r9.w, r10.x
  and r9.w, r9.w, l(0x3f800000)
  sample_l_indexable(texture2d)(float,float,float,float) r3.x, r3.xyxx, t3.xyzw, s14, l(0.000000)
  mad r10.x, r8.w, r11.z, r9.z
  lt r3.x, r3.x, r10.x
  and r3.x, r3.x, l(0x3f800000)
  sample_l_indexable(texture2d)(float,float,float,float) r10.x, r10.ywyy, t3.xyzw, s14, l(0.000000)
  lt r10.x, r10.x, r10.z
  and r10.x, r10.x, l(0x3f800000)
  add r6.z, r6.z, r9.w
  add r3.x, r3.x, r6.z
  add r3.x, r10.x, r3.x
  add r0.z, r0.z, r3.x
  iadd r3.z, r3.z, l(4)
endloop
add r2.x, -r0.z, r2.z
mad r0.z, r5.w, r2.x, r0.z
mul r2.xy, -r0.wwww, cb2[53].wzww
exp r2.xy, r2.xyxx
mul r2.xy, r8.zzzz, r2.xyxx
mul r0.w, r9.y, l(1.100000)
mul r3.xyz, r0.wwww, cb2[56].xyzx
mad r3.xyz, cb2[57].xyzx, r9.xxxx, r3.xyzx
mul r3.xyz, r3.xyzx, l(-1.442695, -1.442695, -1.442695, 0.000000)
exp r3.xyz, r3.xyzx
mul r3.xyz, r3.xyzx, cb5[15].xyzx
mul r0.w, r7.w, r2.x
mul r2.z, r4.w, r2.y
mul r9.xyz, r2.zzzz, cb2[58].xyzx
mad r9.xyz, r0.wwww, cb2[59].xyzx, r9.xyzx
mul r3.xyz, r3.xyzx, r9.xyzx
mul r3.xyz, r3.wwww, r3.xyzx
mul r0.z, r0.z, l(0.015625)
mul r3.xyz, r0.zzzz, r3.xyzx
if_z r6.x
  mul r0.z, cb2[54].y, l(12.000000)
  mul r0.w, r8.x, cb2[55].z
  min r0.w, r6.y, r0.w
  mad r2.z, -r8.y, cb2[55].z, r0.w
  mul r5.w, r2.z, l(0.062500)
  dp3 r6.x, cb5[2].xyzx, r4.xyzx
  dp3 r6.y, cb5[3].xyzx, r4.xyzx
  dp3 r4.x, cb5[4].xyzx, r4.xyzx
  div r4.y, r6.w, cb2[55].z
  mad r4.y, r4.y, r5.z, r7.z
  add r4.y, r4.y, l(-6360000.000000)
  div r2.z, r2.z, cb2[55].z
  mul r2.z, r5.z, r2.z
  mul r2.z, r2.z, l(0.062500)
  mul r4.yz, -r4.yyyy, cb2[53].wwzw
  exp r4.yz, r4.yyzy
  mul r4.yz, r5.wwww, r4.yyzy
  mul r8.xz, -r2.zzzz, cb2[53].wwzw
  exp r8.xz, r8.xxzx
  mad r0.y, r0.y, l(0.800000), -r8.y
  mov r9.xyz, l(0,0,0,0)
  mov r10.xyz, l(0,0,0,0)
  mov r11.xy, r2.xyxx
  mov r2.z, r4.y
  mov r5.w, r4.z
  mov r6.z, l(0)
  loop
    ige r8.w, r6.z, l(16)
    breakc_nz r8.w
    itof r8.w, r6.z
    add r8.w, r0.x, r8.w
    mul r8.w, r8.w, l(0.062500)
    mad r9.w, r0.w, r8.w, r6.w
    mad r12.xyz, r9.wwww, r5.xyzx, r7.xyzx
    add r11.x, r2.z, r11.x
    add r11.y, r5.w, r11.y
    dp3 r9.w, r12.xyzx, cb5[16].xyzx
    dp3 r10.w, r12.xyzx, r12.xyzx
    add r10.w, r10.w, l(-41473600913408.000000)
    mad r10.w, r9.w, r9.w, -r10.w
    sqrt r10.w, r10.w
    add r9.w, -r9.w, r10.w
    add r10.w, r12.z, l(-6360000.000000)
    mul r11.z, r9.w, cb5[16].z
    mul r12.xy, r11.zzzz, -cb2[53].wzww
    mul r12.zw, r10.wwww, -cb2[53].wwwz
    mad r11.zw, r11.zzzz, -cb2[53].wwwz, r12.zzzw
    exp r11.zw, r11.zzzw
    exp r12.zw, r12.zzzw
    add r11.zw, r11.zzzw, -r12.zzzw
    mul r12.xy, r12.xyxx, l(0.693147182, 0.693147182, 0.000000, 0.000000)
    div r12.xy, r9.wwww, r12.xyxx
    mad r8.w, r8.w, r0.y, r8.y
    mad r13.x, r6.x, r8.w, cb5[2].w
    mad r13.y, r6.y, r8.w, cb5[3].w
    mad r8.w, r4.x, r8.w, cb5[4].w
    sample_l_indexable(texture2d)(float,float,float,float) r9.w, r13.xyxx, t25.yzwx, s0, l(0.000000)
    lt r8.w, r9.w, r8.w
    mov_sat r12.zw, r13.xxxy
    ne r12.zw, r12.zzzw, r13.xxxy
    or r9.w, r12.w, r12.z
    or r8.w, r8.w, r9.w
    movc r8.w, r8.w, l(1.000000), cb2[54].z
    mad r11.zw, r11.zzzw, r12.xxxy, r11.xxxy
    mul r9.w, r11.w, l(1.100000)
    mul r12.xyz, r9.wwww, cb2[56].xyzx
    mad r12.xyz, cb2[57].xyzx, r11.zzzz, r12.xyzx
    mul r12.xyz, r12.xyzx, l(-1.442695, -1.442695, -1.442695, 0.000000)
    exp r12.xyz, r12.xyzx
    mul r12.xyz, r8.wwww, r12.xyzx
    mad r9.xyz, r2.zzzz, r12.xyzx, r9.xyzx
    mad r10.xyz, r5.wwww, r12.xyzx, r10.xyzx
    mul r2.z, r8.x, r2.z
    mul r5.w, r8.z, r5.w
    iadd r6.z, r6.z, l(1)
  endloop
  mul r0.xyw, r7.wwww, r9.xyxz
  mul r2.xyz, r4.wwww, r10.xyzx
  mul r2.xyz, r2.xyzx, cb2[56].xyzx
  mad r0.xyw, r0.xyxw, cb2[57].xyxz, r2.xyxz
  mul r0.xyw, r0.xyxw, cb5[15].xyxz
  mad r3.xyz, r0.xywx, r0.zzzz, r3.xyzx
endif
max r0.x, r2.w, l(0.000010)
min r3.w, r0.x, l(50000.000000)
store_uav_typed u0.xyzw, r1.xyzw, r3.xyzw
ret
// Approximately 289 instruction slots used
