Compensate for off-screen pixels when rendering the background