Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- sampler2D input : register(s0);
- float4 main(float2 uv : TEXCOORD) : COLOR
- {
- //colorin is the original color of the pixel, colorout the altered color
- float4 colorin, colorout;
- colorin = tex2D( input , uv.xy);
- colorout = colorin;
- if((colorin.g + colorin.b) < colorin.r )
- {
- colorout.r = colorin.r;
- colorout.g = 0;
- colorout.b = 0;
- }else
- {
- colorout.rgb = dot(colorin.rgb, colorin.rgb ) * dot(colorin.rgb, float4(2, 1, 2, 1) );
- }
- return colorout;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement