//TAA objects PS from cache.
//
// Generated by Microsoft (R) HLSL Shader Compiler 10.0.10011.16384
//
//   using 3Dmigoto v1.3.16 on Fri Jan 14 20:07:49 2022
//
//
// Buffer Definitions:
//
// cbuffer ConstBuf__modelData
// {
//
//   struct ModelData
//   {
//
//       uint lightGroupID;             // Index:    0
//       uint modelFlags;               // Index:    0.y
//       float lodFade;                 // Index:    0.z
//       float displacementBlend;       // Index:    0.w
//       int turbulenceDataIdx;         // Index:    1
//       int instanceOffset;            // Index:    1.y
//       int characterFxIdx;            // Index:    1.z
//       uint debugRenderChannel;       // Index:    1.w
//       uint decayWriteOffset;         // Index:    2
//       uint decayWriteMaxCount;       // Index:    2.y
//       uint decayAtomicCounterIndex;  // Index:    2.z
//       float modelAlpha;              // Index:    2.w
//       float emissiveScale;           // Index:    3
//       float desaturationScale;       // Index:    3.y
//       float decayCoverageEstimation; // Index:    3.z
//       float3 quantScale;             // Index:    4
//       float3 quantBias;              // Index:    5
//
//   } resourceTables__modelData;       // Index:    0-5.z            Components:    23
//
// }
//
// cbuffer ConstBuf__viewData
// {
//
//   struct ViewData
//   {
//
//       float4x4 view;                 // Index:    0
//       float4x4 invView;              // Index:    4
//       float4x4 proj;                 // Index:    8
//       float4x4 invViewProjNoZReproj; // Index:   12
//       float4x4 viewProj;             // Index:   16
//       float4x4 invViewProj;          // Index:   20
//       float4x4 previousViewProj;     // Index:   24
//       float4 prevLodEyePos;          // Index:   28
//       float4 lodEyePos;              // Index:   29
//       float4 viewDirDepthBias;       // Index:   30
//       float3 eyePos;                 // Index:   31
//       float2 viewportSize;           // Index:   32
//       float2 invViewportSize;        // Index:   32.z
//       float4 mirrorPlaneWS;          // Index:   33
//       float2 mirrorViewportSize;     // Index:   34
//       float2 opaqueRefractionViewportSize;// Index:   34.z
//       float windTime;                // Index:   35
//       float deltaTime;               // Index:   35.y
//       float depthReprojectScale;     // Index:   35.z
//       float depthReprojectBias;      // Index:   35.w
//       uint shadowViewType;           // Index:   36
//       float normalDepthBias;         // Index:   36.y
//       float noNormalAA;              // Index:   36.z
//       float noNormalFromAlpha;       // Index:   36.w
//       float noOpaqueTransparency;    // Index:   37
//       float translucentAmount;       // Index:   37.y
//       uint framePhase;               // Index:   37.z
//       float cameraAmbientExposure;   // Index:   37.w
//       float fxExposure;              // Index:   38
//       float fxAmbientExposure;       // Index:   38.y
//       uint checkerboardPhase;        // Index:   38.z
//       float sparkleIntensityScale;   // Index:   38.w
//
//   } resourceTables__viewData;        // Index:    0-38             Components:   156
//
// }
//
// cbuffer ConstBuf__materialData
// {
//
//   struct MaterialData
//   {
//
//       float3 Layer1_emissive_matU;   // Index:    0
//       float3 Layer1_emissive_matV;   // Index:    1
//       float3 Layer1_alpha_matU;      // Index:    2
//       float3 Layer1_alpha_matV;      // Index:    3
//       float3 LayerX_emissive_matU;   // Index:    4
//       float3 LayerX_emissive_matV;   // Index:    5
//       float3 LayerX_alpha_matU;      // Index:    6
//       float3 LayerX_alpha_matV;      // Index:    7
//       float3 Layer0_emissive_matU;   // Index:    8
//       float3 Layer0_emissive_matV;   // Index:    9
//
//   } resourceTables__materialData;    // Index:    0-9.z            Components:    39
                                        // Textures:  t10-t14
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// resourceTables__viewData__smpLinear    sampler      NA          NA    1        1
// resourceTables__viewData__smpLowAniso    sampler      NA          NA    2        1
// resourceTables__materialData.material_dudv1    texture  float4          2d   10        1
// resourceTables__materialData.layer_0__emissive    texture  float4          2d   11        1
// resourceTables__materialData.Layer1_emissive    texture  float4          2d   12        1
// resourceTables__materialData.Layer1_opacity    texture  float4          2d   13        1
// resourceTables__materialData.Layer1_alpha    texture  float4          2d   14        1
// ConstBuf__modelData               cbuffer      NA          NA    1        1
// ConstBuf__viewData                cbuffer      NA          NA    2        1
// ConstBuf__materialData            cbuffer      NA          NA    3        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float   xy
// VERT_ID                  0   x           1     NONE    uint
// TEXCOORD                 0   xy          2     NONE   float   xy
// TEXCOORD                 1   xy          3     NONE   float   xy
// NORMAL                   0   xyz         4     NONE   float
// TANGENT                  0   xyz         5     NONE   float
// BINORMAL                 0   xyz         6     NONE   float
// TEXCOORD                 8   xyz         7     NONE   float   xyz
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Target                0   xyzw        0   TARGET   float   xyzw
// SV_Target                1   xy          1   TARGET   float   xy
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_constantbuffer cb1[4], immediateIndexed
dcl_constantbuffer cb2[33], immediateIndexed
dcl_constantbuffer cb3[10], immediateIndexed
dcl_sampler s1, mode_default
dcl_sampler s2, mode_default
dcl_resource_texture2d (float,float,float,float) t10
dcl_resource_texture2d (float,float,float,float) t11
dcl_resource_texture2d (float,float,float,float) t12
dcl_resource_texture2d (float,float,float,float) t13
dcl_resource_texture2d (float,float,float,float) t14
dcl_input_ps_siv linear noperspective v0.xy, position
dcl_input_ps linear v2.xy
dcl_input_ps linear v3.xy
dcl_input_ps linear v7.xyz
dcl_output o0.xyzw
dcl_output o1.xy
dcl_temps 50
dcl_resource_texture2d (float,float,float,float) t125
ld_indexable(texture2d)(float,float,float,float) r40.xyzw, l(0, 0, 0, 0), t125.xyzw

mul r0.xy, v0.xyxx, cb2[32].zwzz
mad r0.xy, r0.xyxx, l(2.000000, -2.000000, 0.000000, 0.000000), l(-1.000000, 1.000000, 0.000000, 0.000000)
mul r0.zw, v3.xxxy, l(0.000000, 0.000000, 0.500000, 0.500000)
sample_indexable(texture2d)(float,float,float,float) r0.zw, r0.zwzz, t10.zwxy, s1
mad r0.zw, r0.zzzw, l(0.000000, 0.000000, 2.000000, 2.000000), l(0.000000, 0.000000, -0.996078432, -0.996078432)
mov r1.xw, v2.xxxy
mov r1.y, l(1.000000)
dp2 r1.z, l(1.000000, 0.100000, 0.000000, 0.000000), r1.xyxx
mad r2.xy, r0.zwzz, l(-0.050000, 0.050000, 0.000000, 0.000000), v3.xyxx
mov r2.z, l(1.000000)
dp3 r1.x, cb3[2].xyzx, r2.xyzx
dp3 r1.y, cb3[3].xyzx, r2.xyzx
mov r3.xy, v3.xyxx
mov r3.z, l(1.000000)
dp3 r4.x, cb3[6].xyzx, r3.xyzx
dp3 r4.y, cb3[7].xyzx, r3.xyzx
dp3 r5.x, l(0.707106888, -0.707106650, 0.499999881, 0.000000), r3.xyzx
dp3 r5.y, l(0.707106650, 0.707106888, -0.207106769, 0.000000), r3.xyzx
sample_indexable(texture2d)(float,float,float,float) r6.xyz, r1.zwzz, t11.xyzw, s1
mul r6.xyz, r6.xyzx, l(3.500000, 3.500000, 3.500000, 0.000000)
sample_indexable(texture2d)(float,float,float,float) r0.z, r2.xyxx, t13.xzyw, s2
sample_indexable(texture2d)(float,float,float,float) r0.w, r1.xyxx, t14.xywz, s2
mul_sat r0.z, r0.z, r0.w
lt r0.w, l(0.000000), r0.z
if_nz r0.w
  dp3 r1.x, cb3[0].xyzx, r2.xyzx
  dp3 r1.y, cb3[1].xyzx, r2.xyzx
  sample_indexable(texture2d)(float,float,float,float) r1.xyz, r1.xyxx, t12.xyzw, s1
  mad r1.xyz, r1.xyzx, l(0.142209, 0.184951, 0.206770, 0.000000), -r6.xyzx
  mad r6.xyz, r0.zzzz, r1.xyzx, r6.xyzx
endif
sample_indexable(texture2d)(float,float,float,float) r0.z, v3.xyxx, t13.xzyw, s2
sample_indexable(texture2d)(float,float,float,float) r0.w, r4.xyxx, t14.xzwy, s2
mul r0.w, r0.z, r0.w
max r0.w, r0.w, l(0.000000)
add r0.w, r0.w, l(-0.129272)
mul_sat r0.w, r0.w, l(1.82142735)
lt r1.x, l(0.000000), r0.w
if_nz r1.x
  dp3 r1.x, cb3[4].xyzx, r3.xyzx
  dp3 r1.y, cb3[5].xyzx, r3.xyzx
  sample_indexable(texture2d)(float,float,float,float) r1.xyz, r1.xyxx, t12.xyzw, s1
  mul r0.w, r0.w, l(0.750000)
  mad r1.xyz, r1.xyzx, l(0.288790, 0.332693487, 0.350551, 0.000000), -r6.xyzx
  mad r6.xyz, r0.wwww, r1.xyzx, r6.xyzx
endif
sample_indexable(texture2d)(float,float,float,float) r0.w, r5.xyxx, t13.yzwx, s2
mul r1.x, r0.z, r0.w
lt r1.x, r1.x, l(0.500000)
mad r0.z, -r0.w, r0.z, l(1.000000)
mad_sat r0.z, -r0.z, l(2.000000), l(1.000000)
movc r0.z, r1.x, l(0), r0.z
lt r0.w, l(0.000000), r0.z
if_nz r0.w
  dp3 r1.x, cb3[8].xyzx, r3.xyzx
  dp3 r1.y, cb3[9].xyzx, r3.xyzx
  sample_indexable(texture2d)(float,float,float,float) r1.xyz, r1.xyxx, t12.xyzw, s1
  mad r1.xyz, r1.xyzx, l(3.000000, 1.771857, 0.750474036, 0.000000), -r6.xyzx
  mad r6.xyz, r0.zzzz, r1.xyzx, r6.xyzx
endif
mul o0.xyz, r6.xyzx, cb1[3].xxxx
max r0.z, |v7.z|, l(0.000001)

mov r37.xyz, v7.xyzx
ld_indexable(texture2d)(float,float,float,float) r41.xyzw, l(2, 0, 0, 0), t125.xyzw
ge r42.x, r41.x, l(5.0)
if_z r42.x
add r40.w, r37.z, -r41.y
mad r37.x, r41.x, r40.w, r37.x
else
add r40.w, r37.z, -r40.y
mad r37.x, r40.x, r40.w, r37.x
endif

div r0.zw, r37.xxxy, r0.zzzz
add o1.xy, -r0.zwzz, r0.xyxx
mov o0.w, l(-1000000.000000)
ret
// Approximately 66 instruction slots used
