Sets the image sampling factors.