// shadows

cbuffer g_CameraVS_CB : register(b0)
{

  struct
  {
    row_major float4x4 vs_viewProj;
    row_major float4x4 vs_view;
    float4 vs_worldCamPos;
    float4 vs_projection_params;
    float4 vs_inverse_projection_xy;
    float4 vs_frustum_params;
    float4 vs_inverse_projection2;
    float4 vs_cameraOrigin;
  } g_CameraVS : packoffset(c0);

}

cbuffer g_InstanceVS_CB : register(b1)
{

  struct
  {
    row_major float4x4 vs_world;
  } g_InstanceVS : packoffset(c0);

}



// 3Dmigoto declarations
#define cmp -
Texture1D<float4> IniParams : register(t120);
Texture2D<float4> StereoParams : register(t125);


void main( 
  float4 v0 : POSITION0,
  out float4 o0 : SV_Position0)
{
  float4 r0,r1;
  uint4 bitmask, uiDest;
  float4 fDest;

  r0.xyz = g_InstanceVS.vs_world._m10_m11_m12 * v0.yyy;
  r0.xyz = v0.xxx * g_InstanceVS.vs_world._m00_m01_m02 + r0.xyz;
  r0.xyz = v0.zzz * g_InstanceVS.vs_world._m20_m21_m22 + r0.xyz;
  r0.xyz = g_InstanceVS.vs_world._m30_m31_m32 + r0.xyz;
  r1.xyzw = g_CameraVS.vs_viewProj._m10_m11_m12_m13 * r0.yyyy;
  r1.xyzw = r0.xxxx * g_CameraVS.vs_viewProj._m00_m01_m02_m03 + r1.xyzw;
  r0.xyzw = r0.zzzz * g_CameraVS.vs_viewProj._m20_m21_m22_m23 + r1.xyzw;
  o0.xyzw = g_CameraVS.vs_viewProj._m30_m31_m32_m33 + r0.xyzw;
  
  return;
}

/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.29.952.3111
//
//   using 3Dmigoto v1.2.39 on Fri Jul 01 18:58:17 2016
//
//
// Buffer Definitions: 
//
// cbuffer g_CameraVS_CB
// {
//
//   struct CameraVS
//   {
//       
//       row_major float4x4 vs_viewProj;// Offset:    0
//       row_major float4x4 vs_view;    // Offset:   64
//       float4 vs_worldCamPos;         // Offset:  128
//       float4 vs_projection_params;   // Offset:  144
//       float4 vs_inverse_projection_xy;// Offset:  160
//       float4 vs_frustum_params;      // Offset:  176
//       float4 vs_inverse_projection2; // Offset:  192
//       float4 vs_cameraOrigin;        // Offset:  208
//
//   } g_CameraVS;                      // Offset:    0 Size:   224
//
// }
//
// cbuffer g_InstanceVS_CB
// {
//
//   struct InstanceVS
//   {
//       
//       row_major float4x4 vs_world;   // Offset:    0
//
//   } g_InstanceVS;                    // Offset:    0 Size:    64
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// g_CameraVS_CB                     cbuffer      NA          NA    0        1
// g_InstanceVS_CB                   cbuffer      NA          NA    1        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// POSITION                 0   xyzw        0     NONE   float   xyz 
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Position              0   xyzw        0      POS   float   xyzw
//
vs_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer cb0[4], immediateIndexed
dcl_constantbuffer cb1[4], immediateIndexed
dcl_input v0.xyz
dcl_output_siv o0.xyzw, position
dcl_temps 2
mul r0.xyz, v0.yyyy, cb1[1].xyzx
mad r0.xyz, v0.xxxx, cb1[0].xyzx, r0.xyzx
mad r0.xyz, v0.zzzz, cb1[2].xyzx, r0.xyzx
add r0.xyz, r0.xyzx, cb1[3].xyzx
mul r1.xyzw, r0.yyyy, cb0[1].xyzw
mad r1.xyzw, r0.xxxx, cb0[0].xyzw, r1.xyzw
mad r0.xyzw, r0.zzzz, cb0[2].xyzw, r1.xyzw
add o0.xyzw, r0.xyzw, cb0[3].xyzw
ret 
// Approximately 9 instruction slots used

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
