CStats:MinPix
The MinPix method returns the pixel coordinate of the minimum value inside a rectangular region of the image. The rectangle and image must have been previously initialized for the CStats object.
x, y = CStats:MinPix() |
Suppose a CImage I and a CRect R exist. The following script fragment returns the location of the minimum value inside a rectangle:
|
-- create a CStats object |
|
-- specify CImage and CRect to measure |
|
-- get the column and row of the minimum value |
|
-- list the result |
|
-- when done with S, remove it from memory |