PasteAll.org
sampler s0 : register(s0);

float4 main(float2 tex : TEXCOORD0) : COLOR
{

float exposure = float(1);
float offset = float(0);
float gamma = float(1);
gamma = 1/gamma;

float4 input = tex2D(s0,tex);
float4 output = float4(1,1,1,1);

//calculate exposure
input *= exposure;


//DRAW Original
if (tex.y<0.5){
output = tex2D(s0,tex);


//DRAW Exposure + Luminance (offset) + gamma
}else {
output = pow(input + offset,gamma);
}



return output;
}
  1. sampler s0 : register(s0);
  2.  
  3. float4 main(float2 tex : TEXCOORD0) : COLOR
  4. {
  5.  
  6.        float exposure = float(1);
  7.        float offset = float(0);
  8.         float gamma = float(1);
  9.         gamma = 1/gamma;
  10.  
  11.        float4 input = tex2D(s0,tex);
  12.        float4 output = float4(1,1,1,1);
  13.  
  14.        //calculate exposure
  15.        input *= exposure;
  16.  
  17.  
  18.        //DRAW Original
  19.        if (tex.y<0.5){
  20.                output = tex2D(s0,tex);
  21.  
  22.  
  23.        //DRAW Exposure + Luminance (offset) + gamma
  24.        }else {
  25.                 output = pow(input + offset,gamma);
  26.        }
  27.  
  28.  
  29.  
  30.        return output;
  31. }
go to heaven