Texture2D texture0 : register( t0 ); SamplerState sampler0 : register( s0 ); struct VS_OUTPUT { float4 position : SV_POSITION; float2 tex : TEXCOORD0; float4 color : COLOR0; }; cbuffer psConstants1 : register( b1 ) { float g_scale; }; float4 PS(VS_OUTPUT input) : SV_Target { return texture0.Sample(sampler0, input.tex / g_scale) * input.color; }