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

SamplerState sampler_tex_0__s : register(s0);
SamplerState sampler_tex_1__s : register(s1);
Texture2D<float4> tex_0_ : register(t0);
Texture2D<float4> tex_1_ : register(t1);


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


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

  r0.xyzw = tex_0_.Sample(sampler_tex_0__s, v0.xy).xyzw;
  r1.xyzw = tex_1_.Sample(sampler_tex_1__s, w0.xy).xyzw;
  r0.xyzw = -r1.xyzw + r0.xyzw;
  r1.xyzw = cmp(float4(0,0,0,0) < r0.xyzw);
  r2.xyzw = cmp(r0.xyzw < float4(0,0,0,0));
  r0.xyzw = frac(r0.xyzw);
  r1.xyzw = (int4)-r1.xyzw + (int4)r2.xyzw;
  r1.xyzw = (int4)r1.xyzw;
  r1.xyzw = float4(1,1,1,1) + r1.xyzw;
  r2.xyzw = cmp(r1.xyzw < float4(-0,-0,-0,-0));
  r1.xyzw = cmp(float4(-0,-0,-0,-0) < r1.xyzw);
  r1.xyzw = (int4)-r2.xyzw + (int4)r1.xyzw;
  r1.xyzw = (int4)r1.xyzw;
  r1.xyzw = float4(1,1,1,1) + r1.xyzw;
  r0.xyzw = r1.xyzw * float4(0.00392156886,0.00392156886,0.00392156886,0.00392156886) + r0.xyzw;
  r1.x = dot(r0.xyz, float3(1,1,1));
  r1.y = cmp(0 < r1.x);
  r1.x = cmp(r1.x < 0);
  r1.x = (int)-r1.y + (int)r1.x;
  r1.x = (int)r1.x;
  r2.xyz = r0.xyz;
  r2.w = 1;
  r0.xyz = float3(1,1,1);
  r2.xyzw = r2.xyzw + -r0.zzzw;
  o0.xyzw = r1.xxxx * r2.xyzw + r0.xyzw;
  return;
}

/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Original ASM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
// Generated by Microsoft (R) HLSL Shader Compiler 9.30.9200.20546
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim Slot Elements
// ------------------------------ ---------- ------- ----------- ---- --------
// sampler_tex[0]                    sampler      NA          NA    0        1
// sampler_tex[1]                    sampler      NA          NA    1        1
// tex[0]                            texture  float4          2d    0        1
// tex[1]                            texture  float4          2d    1        1
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// TEXCOORD                 0   xy          0     NONE   float   xy  
// TEXCOORD                 1     zw        0     NONE   float     zw
//
//
// 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 s0, mode_default
dcl_sampler s1, mode_default
dcl_resource_texture2d (float,float,float,float) t0
dcl_resource_texture2d (float,float,float,float) t1
dcl_input_ps linear v0.xy
dcl_input_ps linear v0.zw
dcl_output o0.xyzw
dcl_temps 3
sample_indexable(texture2d)(float,float,float,float) r0.xyzw, v0.xyxx, t0.xyzw, s0
sample_indexable(texture2d)(float,float,float,float) r1.xyzw, v0.zwzz, t1.xyzw, s1
add r0.xyzw, r0.xyzw, -r1.xyzw
lt r1.xyzw, l(0.000000, 0.000000, 0.000000, 0.000000), r0.xyzw
lt r2.xyzw, r0.xyzw, l(0.000000, 0.000000, 0.000000, 0.000000)
frc r0.xyzw, r0.xyzw
iadd r1.xyzw, -r1.xyzw, r2.xyzw
itof r1.xyzw, r1.xyzw
add r1.xyzw, r1.xyzw, l(1.000000, 1.000000, 1.000000, 1.000000)
lt r2.xyzw, r1.xyzw, l(-0.000000, -0.000000, -0.000000, -0.000000)
lt r1.xyzw, l(-0.000000, -0.000000, -0.000000, -0.000000), r1.xyzw
iadd r1.xyzw, -r2.xyzw, r1.xyzw
itof r1.xyzw, r1.xyzw
add r1.xyzw, r1.xyzw, l(1.000000, 1.000000, 1.000000, 1.000000)
mad r0.xyzw, r1.xyzw, l(0.003922, 0.003922, 0.003922, 0.003922), r0.xyzw
dp3 r1.x, r0.xyzx, l(1.000000, 1.000000, 1.000000, 0.000000)
lt r1.y, l(0.000000), r1.x
lt r1.x, r1.x, l(0.000000)
iadd r1.x, -r1.y, r1.x
itof r1.x, r1.x
mov r2.xyz, r0.xyzx
mov r2.w, l(1.000000)
mov r0.xyz, l(1.000000,1.000000,1.000000,0)
add r2.xyzw, -r0.zzzw, r2.xyzw
mad o0.xyzw, r1.xxxx, r2.xyzw, r0.xyzw
ret 
// Approximately 26 instruction slots used

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