//
// Generated by Microsoft (R) HLSL Shader Compiler 9.29.952.3111
//
//   using 3Dmigoto v1.2.67 on Mon Jan 01 13:11:46 2018
//
//
// Buffer Definitions: 
//
// cbuffer $Globals
// {
//
//   float4 lightCount;                 // Offset:    0 Size:    16 [unused]
//   float4 ambient;                    // Offset:   16 Size:    16 [unused]
//   float4 lightInfo[4];               // Offset:   32 Size:    64
//   float4 g_vAmbientSettings;         // Offset:   96 Size:    16 [unused]
//      = 0x00000000 0x00000000 0x00000000 0x00000000 
//   float4 g_vScreenDepthRect;         // Offset:  112 Size:    16 [unused]
//   float4 g_vDitherSettings;          // Offset:  128 Size:    16 [unused]
//   float4 g_ColorK;                   // Offset:  144 Size:    16 [unused]
//      = 0x3e8a3d71 0x3f2b851f 0x3d75c28f 0x00000000 
//   float4 LevelMin;                   // Offset:  160 Size:    16 [unused]
//      = 0x3dcccccd 0x3dcccccd 0x3dcccccd 0x00000000 
//   float4 LevelMax;                   // Offset:  176 Size:    16 [unused]
//      = 0x3f4ccccd 0x3f4ccccd 0x3f4ccccd 0x00000000 
//   float4 MaxAdd;                     // Offset:  192 Size:    16 [unused]
//      = 0x3dcccccd 0x3dcccccd 0x3dcccccd 0x00000000 
//   float4 MinSub;                     // Offset:  208 Size:    16 [unused]
//      = 0x3ca3d70a 0x3ca3d70a 0x3ca3d70a 0x00000000 
//   float4 Color;                      // Offset:  224 Size:    16 [unused]
//   float4 Settings;                   // Offset:  240 Size:    16 [unused]
//   float4 Settings2;                  // Offset:  256 Size:    16 [unused]
//   float4 Settings3;                  // Offset:  272 Size:    16 [unused]
//   float4 Settings4;                  // Offset:  288 Size:    16 [unused]
//   float4 Transform;                  // Offset:  304 Size:    16
//   float4 g_vDepthCoordsClamp;        // Offset:  320 Size:    16 [unused]
//   float4 CamPos;                     // Offset:  336 Size:    16
//   float4 g_vCenterOffs;              // Offset:  352 Size:    16 [unused]
//   float4 g_vHFrustrum;               // Offset:  368 Size:    16 [unused]
//   float4 g_vVFrustrum;               // Offset:  384 Size:    16 [unused]
//   float4 g_avNoise[8];               // Offset:  400 Size:   128 [unused]
//   float4x4 g_mView;                  // Offset:  528 Size:    64
//   float4 g_PixelsDir[8];             // Offset:  592 Size:   128 [unused]
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// $Globals                          cbuffer      NA          NA    0        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// POSITION                 0   xy          0     NONE   float   xy  
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Position              0   xyzw        0      POS   float   xyzw
// TEXCOORD                 0   xy          1     NONE   float   xy  
// TEXCOORD                 1   xyzw        2     NONE   float   xyzw
//
vs_4_0
dcl_constantbuffer cb0[35], immediateIndexed
dcl_input v0.xy
dcl_output_siv o0.xyzw, position
dcl_output o1.xy
dcl_output o2.xyzw
// dcl_temps updated : previous = dcl_temps 2
dcl_temps 5
// added 3dmigoto declaration
dcl_resource_texture1d (float,float,float,float) t120
ld_indexable(texture1d)(float,float,float,float) r3.xyzw, l(0, 0, 0, 0), t120.xyzw
mov r4.x, r3.w
mov r4.y, r3.w
mov r4.zw, l(1.0, 1.0)
// end of 3dmigoto declaration
add_sat r0.x, v0.x, v0.x
mad o1.x, r0.x, cb0[19].z, cb0[19].x
mul_sat r0.x, v0.y, l(-2.000000)
mad o1.y, r0.x, cb0[19].w, cb0[19].y
eq r0.x, cb0[2].w, l(1.000000)
if_nz r0.x
  add r0.xyz, -cb0[2].xyzx, cb0[21].xyzx
  dp3 r0.w, r0.xyzx, r0.xyzx
  sqrt r0.w, r0.w
  div r0.xyz, r0.xyzx, r0.wwww
  mad r0.w, -r0.w, cb0[3].w, l(1.000000)
  max r0.w, r0.w, l(0.000000)
else 
  mov r0.xyz, cb0[2].xyzx
  mov r0.w, l(1.000000)
endif 
// replacing matrix usage :dp3 r1.x, r0.xyzx, cb0[33].xyzx
dp3 r2.x, r0.xyzx, cb0[33].xyzx
mul r1.x, r2.x, r4.x
// replacing matrix usage :dp3 r1.y, r0.xyzx, cb0[34].xyzx
dp3 r2.y, r0.xyzx, cb0[34].xyzx
mul r1.y, r2.y, r4.y
mul o2.xy, r0.wwww, r1.xyxx
eq r0.x, cb0[4].w, l(1.000000)
if_nz r0.x
  add r0.xyz, -cb0[4].xyzx, cb0[21].xyzx
  dp3 r0.w, r0.xyzx, r0.xyzx
  sqrt r0.w, r0.w
  div r0.xyz, r0.xyzx, r0.wwww
  mad r0.w, -r0.w, cb0[5].w, l(1.000000)
  max r0.w, r0.w, l(0.000000)
else 
  mov r0.xyz, cb0[4].xyzx
  mov r0.w, l(1.000000)
endif 
// replacing matrix usage :dp3 r1.z, r0.xyzx, cb0[33].xyzx
dp3 r2.z, r0.xyzx, cb0[33].xyzx
// replacing matrix usage :dp3 r1.w, r0.xyzx, cb0[34].xyzx
dp3 r2.w, r0.xyzx, cb0[34].xyzx
mul o2.zw, r0.wwww, r1.zzzw
mov o0.xy, v0.xyxx
mov o0.zw, l(0,0,0,1.000000)
ret 
// Approximately 37 instruction slots used
