// ---- Created with 3Dmigoto v1.2.35 on Tue Apr 26 22:30:27 2016

SamplerState SS_ClampPoint_s : register(s2);
SamplerState SS_ClampLinear_s : register(s3);
Texture2D<float4> g_SourceTex : register(t0);
Texture3D<float4> g_InputTexLut : register(t4);


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


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

  r0.xyzw = g_SourceTex.SampleLevel(SS_ClampPoint_s, v1.xy, 0).xyzw;
  r1.xyz = r0.xyz * float3(0.9375,0.9375,0.9375) + float3(0.03125,0.03125,0.03125);
  r0.xyz = g_InputTexLut.Sample(SS_ClampLinear_s, r1.xyz).xyz;
  o0.xyzw = max(float4(0,0,0,0), r0.xyzw);
  return;
}

/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Original ASM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.30.9200.20546
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// SS_ClampPoint                     sampler      NA          NA    2        1
// SS_ClampLinear                    sampler      NA          NA    3        1
// g_SourceTex                       texture  float4          2d    0        1
// g_InputTexLut                     texture  float4          3d    4        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Position              0   xyzw        0      POS   float       
// TEXCOORD                 0   xy          1     NONE   float   xy  
//
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// SV_Target                0   xyzw        0   TARGET   float   xyzw
//
ps_5_0
dcl_globalFlags refactoringAllowed
dcl_sampler s2, mode_default
dcl_sampler s3, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_resource_texture3d (float,float,float,float) t4
dcl_input_ps linear v1.xy
dcl_output o0.xyzw
dcl_temps 2
sample_l_indexable(texture2d)(float,float,float,float) r0.xyzw, v1.xyxx, t0.xyzw, s2, l(0.000000)
mad r1.xyz, r0.xyzx, l(0.937500, 0.937500, 0.937500, 0.000000), l(0.031250, 0.031250, 0.031250, 0.000000)
sample_indexable(texture3d)(float,float,float,float) r0.xyz, r1.xyzx, t4.xyzw, s3
max o0.xyzw, r0.xyzw, l(0.000000, 0.000000, 0.000000, 0.000000)
ret 
// Approximately 5 instruction slots used

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