CFwhm:new
The new method constructs a new instance of a CFwhm object. The CFwhm class includes properties that control calculation of a FWHM value and its centroid position. Two different constructor overloads are available to create a new CFwhm and initialize the properties.
F = CFwhm:new()
Creates a default CFwhm F with properties initialized to default values.
F = CFwhm:new( CFwhm_old )
This is a copy constructor. It creates a new CFwhm F initialized to the properties of the existing CFwhm object CFwhm_old.
On failure, nil is returned.
Two overloads are provided for the CFwhm class. They create a default CFwhm and a copy of a CFwhm. If you pass something other than nil or another CFwhm, the default constructor is used.
The following script illustrates using both constructors. All produce the same result:
|
-- create CFwhm object F1 |
|
-- change the sign from the default true |
|
-- copy F1 to a new CFwhm object F2 |
|
-- result: F1 sign = 0 |
|
-- result: F2 sign = 0 |
Mira Pro x64 Script User's Guide, Copyright Ⓒ 2023 Mirametrics,
Inc. All Rights Reserved.