CImExtract:SetParams
The SetParams method changes the properties for extracting sources from an image. The CImExtract properties are initialized to reasonable values. The purpose of this method is to change these properties by setting new values in an ImExtractParams table. See the Mira User's Guide for more information regarding source extraction.
bSuccess = CImExtract:SetParams( ImExtractParams_table) |
where ImExtractParams_table is a table of type ImExtractParams containing properties to change.
On success, true is returned.
Suppose an image window exists on the Mira screen and you wish to draw a point marker on the image. The script below sets several properties for the extraction process before calling Extract. Note that your table does not need to be named Params.
|
-- attach an image window |
|
-- leave script if no image window |
|
|
|
-- get the top-most or only image |
|
-- leave script if no image |
|
|
|
-- create a CImExtract object |
|
-- setup an ImExtractParams table |
|
-- use a comma after each "name=value" pair |
|
|
|
|
|
|
|
|
|
|
|
|
|
-- threshold value = 45 |
|
-- use pixels greater than or equal to threshold |
|
|
|
-- set the new properties |
|
|
|
-- extract sources from image I |
CImExtract class, ImExtractParams Table
Mira Pro x64 Script User's Guide, v.8.73 Copyright Ⓒ 2024
Mirametrics, Inc. All Rights Reserved.