
// Returns the average of 4 nearest neighbour interpolated samples from the input texture.
// It is only used for scaling to half width and height.

float4 PS( VS_to_PS input) : SV_Target {
	return (tex_0.Sample( samConstant, (PixelPos + float2(-0.5f, 0.5f)) / Dimensions )
	      + tex_0.Sample( samConstant, (PixelPos + float2(0.5f, 0.5f)) / Dimensions )
	      + tex_0.Sample( samConstant, (PixelPos + float2(0.5f, -0.5f)) / Dimensions )
	      + tex_0.Sample( samConstant, (PixelPos + float2(-0.5f, -0.5f)) / Dimensions )) * 0.25f;
}
