// AUTOMATICALLY CONVERTED FROM SHADER FIXES 
//
// Generated by Microsoft (R) HLSL Shader Compiler 10.1
//
//   using 3Dmigoto v0.6.89 on Mon Dec 26 00:11:14 2022
//
//
// Buffer Definitions:
//
// cbuffer RenderView
// {
//
//   float4x4 uProjectionMatrix;        // Index:    0 1 2 3          Components:    16
//   float4x4 uModelViewMatrix;         // Index:    4 5 6 7          Components:    16
//   float4x4 uInverseProjectionMatrix; // Index:    8 9 10 11        Components:    16 [unused]
//   float4x4 uPrevProjection;          // Index:   12 13 14 15       Components:    16 [unused]
//   float4x4 uInverseModelViewMatrix;  // Index:   16 17 18 19       Components:    16 [unused]
//   float4x4 uPrevModelView;           // Index:   20 21 22 23       Components:    16 [unused]
//   float4x4 uRotationMatrix;          // Index:   24 25 26 27       Components:    16 [unused]
//   float4x4 uInverseRotationMatrix;   // Index:   28 29 30 31       Components:    16 [unused]
//   float4x4 uTransposedRotationMatrix;// Index:   32 33 34 35       Components:    16 [unused]
//   float4x4 uClipMatrix;              // Index:   36 37 38 39       Components:    16 [unused]
//   float4x4 uInverseClipMatrix;       // Index:   40 41 42 43       Components:    16 [unused]
//   float4x4 uPrevClipMatrix;          // Index:   44 45 46 47       Components:    16 [unused]
//   float4x4 uNormalMatrix;            // Index:   48 49 50 51       Components:    16 [unused]
//   float3 uViewOrigin;                // Index:   52.xyz            Components:     3 [unused]
//   float uViewWidth;                  // Index:   52.w              Components:     1 [unused]
//   float uViewHeight;                 // Index:   53.x              Components:     1 [unused]
//   float uZNear;                      // Index:   53.y              Components:     1 [unused]
//   float uZFar;                       // Index:   53.z              Components:     1 [unused]
//   float2 uInvFocalCoords;            // Index:   54.xy             Components:     2 [unused]
//   float4 uResolutionScale;           // Index:   55.xyzw           Components:     4 [unused]
//   float4 uScreenBounds;              // Index:   56.xyzw           Components:     4 [unused]
//   float4 uFrustumCorners[4];         // Index:   57 58 59 60       Components:    16 [unused]
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// DepthBuffer                       texture   float          2d  110        1
// IniParams                         texture  float4          1d  120        1
// StereoParams                      texture  float4          2d  125        1
// RenderView                        cbuffer      NA          NA    0        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// ATTRIB                   0   xyz         0     NONE   float   xyz
// ATTRIB                   1   xy          1     NONE   float   xy
// ATTRIB                   2   xyzw        2     NONE   float   xyzw
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float   xyzw
// TEXCOORD                 0   xy          1     NONE   float   xy
// COLOR                    0   xyzw        2     NONE   float   xyzw
// P                        0   x           3  RTINDEX    uint   x
//
vs_4_0
dcl_output_siv o3.x, rendertarget_array_index
dcl_constantbuffer CB0[8], immediateIndexed
dcl_resource_texture2d (float,float,float,float) t110
dcl_resource_texture1d (float,float,float,float) t120
dcl_resource_buffer (float,float,float,float) t125
dcl_input v0.xyz
dcl_input v1.xy
dcl_input v2.xyzw
dcl_output_siv o0.xyzw, position
dcl_output o1.xy
dcl_output o2.xyzw
dcl_temps 9
ld_indexable(buffer)(float,float,float,float) r8.xyzw, l(0, 0, 0, 0), t125.xyzw
mov o3.x, r8.z
ld r0.xyzw, l(0, 0, 0, 0), t125.xyzw
ld r1.xyzw, l(3, 0, 0, 0), t120.xyzw
ld r2.xyzw, l(10, 0, 0, 0), t120.xyzw
mul r3.xyzw, v0.yyyy, cb0[5].xyzw
mad r3.xyzw, cb0[4].xyzw, v0.xxxx, r3.xyzw
mad r3.xyzw, cb0[6].xyzw, v0.zzzz, r3.xyzw
add r3.xyzw, r3.xyzw, cb0[7].xyzw
mul r4.xyzw, r3.yyyy, cb0[1].xyzw
mad r4.xyzw, cb0[0].xyzw, r3.xxxx, r4.xyzw
mad r4.xyzw, cb0[2].xyzw, r3.zzzz, r4.xyzw
mad r3.xyzw, cb0[3].xyzw, r3.wwww, r4.xyzw
eq r0.z, r3.w, l(1.000000)
eq r0.w, r2.z, l(1.000000)
and r0.w, r0.w, r0.z
eq r1.x, r1.w, l(1.000000)
and r0.w, r0.w, r1.x
lt r1.xy, l(-0.200000, -0.200000, 0.000000, 0.000000), r3.xyxx
and r0.w, r0.w, r1.x
lt r1.xz, r3.xxyx, l(0.200000, 0.000000, 0.200000, 0.000000)
and r0.w, r0.w, r1.x
and r0.w, r1.y, r0.w
and r0.w, r1.z, r0.w
if_nz r0.w
  mul r0.y, r0.y, r0.x
  mul r0.y, r0.y, l(0.275000)
  resinfo_uint r4.xyzw, l(0), t110.xyzw
  iadd r1.xy, r4.xyxx, l(-1, -1, 0, 0)
  utof r2.yz, r4.xxyx
  mul r0.w, r2.z, l(0.500000)
  utof r1.xy, r1.xyxx
  min r0.w, r0.w, r1.y
  ftoi r4.y, r0.w
  mov r4.zw, l(0,0,0,0)
  mov r0.w, l(0)
  mov r1.yz, l(0,0,0,0)
  mov r2.zw, l(0,0,0,0)
  loop
    utof r5.x, r2.z
    ge r5.x, r5.x, l(300.000000)
    mov r2.w, l(0)
    breakc_nz r5.x
    mad r1.z, r0.x, l(0.00333333341), r1.z
    mad r5.x, r1.z, l(0.500000), l(0.500000)
    mul r5.x, r2.y, r5.x
    max r5.x, r5.x, l(0.000000)
    min r5.x, r1.x, r5.x
    ftoi r4.x, r5.x
    ld r5.xyzw, r4.xyzw, t110.xyzw
    ne r4.x, r5.x, l(1.000000)
    add r5.y, -r5.x, l(1.000000)
    mul r5.y, r5.y, l(0.000010)
    div r5.y, l(0.000010), r5.y
    add r5.x, r5.x, r5.y
    and r4.x, r4.x, r5.x
    eq r5.x, r4.x, l(0.000000)
    if_nz r5.x
      mov r0.w, r0.x
      mov r2.w, l(-1)
      break
    endif
    add r5.y, r0.x, -r1.z
    div r5.y, r0.y, r5.y
    lt r4.x, r4.x, r5.y
    if_nz r4.x
      mov r0.w, l(0)
      mov r2.w, l(0)
      break
    endif
    mov r1.y, r1.z
    iadd r2.z, r2.z, l(1)
    mov r2.w, r5.x
    mov r0.w, l(0)
  endloop
  movc r0.y, r2.w, r0.w, r1.y
  add r3.x, r0.y, r3.x
else
  ne r0.y, r1.w, l(10.000000)
  and r0.y, r0.y, r0.z
  mul r0.x, r0.x, r2.x
  mad r0.x, r0.x, r3.w, r3.x
  movc r3.x, r0.y, r0.x, r3.x
endif
mov r6.xyzw, r3.xyzw
mov o2.xyzw, v2.xyzw
mov o1.xy, v1.xyxx
add r7.x, -r8.y, r6.w
mul r7.y, r8.x, r8.w
mad r7.x, r7.x, r7.y, r6.x
ne r7.y, l(1.000000), r6.w
movc r6.x, r7.y, r7.x, r6.x
mov o0.xyzw, r6.xyzw
ret
// Approximately 86 instruction slots used
