CImageView:SetZoom
The SetZoom method changes the image magnification, or "zoom" factor in the CImageView window.
CImageView:SetZoom( nZoom ) |
Mira displays images with the following zoom factors: 1/16, 1/8, 1/4, 1/2, 1, 2, 4, 8, and 16. This is encoded as the zoom numbers -16, -8, -4, -2, 1, 2, 4 , 8, and 16. The value ofnZoom must be one of these integer zoom numbers.
The following script fragment loads and displays an image and then sets the magnification factor (the zoom) to 1/2 normal by specifying a zoom factor of-2 (see Remarks):
|
-- create a CImage |
|
-- load the from a file named sPath |
|
-- display the image and return the CImageView V |
|
-- set the zoom factor to -2 (magnification = 1/2) |