//AO in animated leaders screen-- disabled
// ---- Created with 3Dmigoto v1.3.16 on Sun Aug 16 01:28:21 2020

Texture2DMS<float> DepthBuffer : register(t1);


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


void main(
  float4 v0 : SV_POSITION0,
  float2 v1 : TEXCOORD1,
  out float oDepth : SV_DEPTH)
{
  float4 r0,r1;
  uint4 bitmask, uiDest;
  float4 fDest;

discard;
  r0.xy = (int2)v0.xy;
  r0.zw = float2(0,0);
  r1.x = DepthBuffer.Load(r0.xy, 0).x;
  r1.x = max(0, r1.x);
  r1.y = DepthBuffer.Load(r0.xy, 1).x;
  r1.x = max(r1.x, r1.y);
  r1.y = DepthBuffer.Load(r0.xy, 2).x;
  r1.x = max(r1.x, r1.y);
  r1.y = DepthBuffer.Load(r0.xy, 3).x;
  r1.x = max(r1.x, r1.y);
  r1.y = DepthBuffer.Load(r0.xy, 4).x;
  r1.x = max(r1.x, r1.y);
  r1.y = DepthBuffer.Load(r0.xy, 5).x;
  r1.x = max(r1.x, r1.y);
  r1.y = DepthBuffer.Load(r0.xy, 6).x;
  r0.x = DepthBuffer.Load(r0.xy, 7).x;
  r0.y = max(r1.x, r1.y);
  oDepth = max(r0.y, r0.x);
  return;
}

/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
// Generated by Microsoft (R) HLSL Shader Compiler 10.0.10011.16384
//
//   using 3Dmigoto v1.3.16 on Sun Aug 16 01:28:21 2020
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// DepthBuffer                       texture   float        2dMS    1        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float   xy
// TEXCOORD                 1   xy          1     NONE   float
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_DEPTH                 0    N/A   oDepth    DEPTH   float    YES
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_resource_texture2dms(0) (float,float,float,float) t1
dcl_input_ps_siv linear noperspective v0.xy, position
dcl_output oDepth
dcl_temps 2
ftoi r0.xy, v0.xyxx
mov r0.zw, l(0,0,0,0)
ldms_indexable(texture2dms)(float,float,float,float) r1.x, r0.xyww, t1.xyzw, l(0)
max r1.x, r1.x, l(0.000000)
ldms_indexable(texture2dms)(float,float,float,float) r1.y, r0.xyww, t1.yxzw, l(1)
max r1.x, r1.y, r1.x
ldms_indexable(texture2dms)(float,float,float,float) r1.y, r0.xyww, t1.yxzw, l(2)
max r1.x, r1.y, r1.x
ldms_indexable(texture2dms)(float,float,float,float) r1.y, r0.xyww, t1.yxzw, l(3)
max r1.x, r1.y, r1.x
ldms_indexable(texture2dms)(float,float,float,float) r1.y, r0.xyww, t1.yxzw, l(4)
max r1.x, r1.y, r1.x
ldms_indexable(texture2dms)(float,float,float,float) r1.y, r0.xyww, t1.yxzw, l(5)
max r1.x, r1.y, r1.x
ldms_indexable(texture2dms)(float,float,float,float) r1.y, r0.xyww, t1.yxzw, l(6)
ldms_indexable(texture2dms)(float,float,float,float) r0.x, r0.xyzw, t1.xyzw, l(7)
max r0.y, r1.y, r1.x
max oDepth, r0.x, r0.y
ret
// Approximately 19 instruction slots used

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