- Initialize the output device before the input image and derive the viewport height from the output device native resolution. - Check if the image height is at least two times the viewport height. - For width, check if the image width less than or equal to the viewport width.