// ---- Created with 3Dmigoto v1.3.16 on Fri Sep 02 18:53:46 2022

cbuffer perSpriteBuffer : register(b0)
{
  row_major float4x4 transform : packoffset(c0);
  float2 textureSize : packoffset(c4);
  float4 color : packoffset(c5);
  float alphaTestVal : packoffset(c6);
}

SamplerState sam_linear_s : register(s0);
Texture2D<float4> tex_diffuse : register(t0);


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


void main(
  float4 v0 : SV_POSITION0,
  float4 v1 : COLOR0,
  float2 v2 : TEXCOORD0,
  out float4 o0 : SV_Target0)
{
  float4 r0,r1;
  uint4 bitmask, uiDest;
  float4 fDest;

  r0.xyzw = tex_diffuse.Sample(sam_linear_s, v2.xy).xyzw;
  r0.xyzw = v1.xyzw * r0.xyzw;
  r1.x = cmp(alphaTestVal >= r0.w);
  if (r1.x != 0) discard;
  o0.xyzw = r0.xyzw;
  return;
}

/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
// Generated by Microsoft (R) HLSL Shader Compiler 6.3.9600.16384
//
//   using 3Dmigoto v1.3.16 on Fri Sep 02 18:53:46 2022
//
//
// Buffer Definitions:
//
// cbuffer perSpriteBuffer
// {
//
//   row_major float4x4 transform;      // Offset:    0 Size:    64 [unused]
//   float2 textureSize;                // Offset:   64 Size:     8 [unused]
//   float4 color;                      // Offset:   80 Size:    16 [unused]
//   float alphaTestVal;                // Offset:   96 Size:     4
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// sam_linear                        sampler      NA          NA    0        1
// tex_diffuse                       texture  float4          2d    0        1
// perSpriteBuffer                   cbuffer      NA          NA    0        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_POSITION              0   xyzw        0      POS   float
// COLOR                    0   xyzw        1     NONE   float   xyzw
// TEXCOORD                 0   xy          2     NONE   float   xy
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Target                0   xyzw        0   TARGET   float   xyzw
//
ps_4_0
dcl_constantbuffer cb0[7], immediateIndexed
dcl_sampler s0, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_input_ps linear v1.xyzw
dcl_input_ps linear v2.xy
dcl_output o0.xyzw
dcl_temps 2
sample r0.xyzw, v2.xyxx, t0.xyzw, s0
mul r0.xyzw, r0.xyzw, v1.xyzw
ge r1.x, cb0[6].x, r0.w
discard_nz r1.x
mov o0.xyzw, r0.xyzw
ret
// Approximately 6 instruction slots used

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