CImageView:GetCursorRect
The GetCursorRect method returns the extent of the image cursor for the current image in the CImageView. This function returns the rectangle limits in pixel coordinates. If the current image has a World Coordinate Calibration ("WCS"), then the pixel coordinates may be converted to world coordinates using CImage:XyToWcs or CImage:XyToWcsStr.
CRect = CImageView:GetCursorRect() |
This returns a CRect containing the xmin, xmax, ymin, and ymax values in pixel coordinates.
On success, this method returns a new CRect object.
On failure, this method returns nil.
Assume that a CImageView object named V exists and refers to an image window. The following script sets the image cursor to an x-range of 100:200 and a y-range of 300:500:
|
-- retrieve the image cursor |
|
-- print the image cursor limits. |
CImageView, CRect class, SetCursorRect, SetCursorExtent, CRect class, Image Coordinate System, Subpixel Coordinate Definition
Mira Pro x64 Script User's Guide, Copyright Ⓒ 2023 Mirametrics,
Inc. All Rights Reserved.