CImExtract:Count
The Count method returns the number of sources extracted from the image using the CImExtract:Extract method.
number = CImExtract:Count() |
On success, this method returns the number of sources extracted from the image.
On failure, this method returns 0.
The following script extracts sources from an image and lists the x,y coordinates for all sources.
|
-- create a CImExtract |
-- select the image from an image window |
|
|
-- get an image window |
|
-- exit if no image window selected |
-- choose the image if image set has > 1 image |
|
|
-- return the number of sources found |
|
|
|
|
|
|
|
|
|
|
|
|
|
-- extract sources from CImage I |
|
|
|
|
|
-- Get the number of sources |
|
|
|
-- t is a table of data for source n |
|
|
|
-- list x,y of source n |
|
|
|
|
CImExtract class, Extract, GetSource, ImExtractParams
Mira Pro x64 Script User's Guide, Copyright Ⓒ 2024 Mirametrics,
Inc. All Rights Reserved.