/* --- Settings --- */ #define TopMargin 50 #define BottonMargin 50 sampler s0 : register(s0); float4 p0 : register(c0); float4 p1 : register(c1); #define width (p0[0]) #define height (p0[1]) float4 main(float2 tex : TEXCOORD0) : COLOR { if (tex.y < TopMargin / height) return float4(0, 0, 0, 0); if (tex.y > 1.0 - BottonMargin / height) return float4(0, 0, 0, 0); return tex2D(s0, tex); }