|
| |
Use as a .NET assembly
Simply set a reference on the SigmaCombine.dll file, then the component is
self-documenting, through the IntelliSense features of Visual Studio.
Use in Windows Scripts or as an ActiveX component
Instantiate the component using CreateObject, with a ProgID = "SyD.SigmaCombine":
General Procedure for Combining Images
- Create a collection of strings, each of which holds the fully qualified
name of one of the FITS files to be combined. In .NET, an ArrayList object is
ideal.
- Create an instance of the SyD.SigmaCombine object.
- Set the Files property by passing in the collection of file names. This
will validate the filenames and ensure they files exist. An exception will be
thrown if any of the files are missing.
- (optional) Call the LoadImages() method. This will open each of the files
and read the image data into memory. LoadImages verifies that the attributes
of each file are consistent with each other; all the files must have the same
dimensions, binning mode, frame type and exposure time. An exception may be
thrown if there are any inconsistencies or invalid file data.
- Call the DoCombine() method.
- The combined image is available as a FITS object by reading the
CombinedImage property. The FITS header data may be examined or altered as
desired.
- Alternatively, call the WriteFITS method, passing the filename of the
destination file.
Example script
Dim objSigmaCombine
objSigmaCombine = CreateObject("SyD.SigmaCombine")
objSigmaCombine.Files = myCollectionOfFiles
objSigmaCombine.LoadImages()
objSigmaCombine.HighReject = 1.0 ' Reject outliers above 1.0 standard deviations
objSigmaCombine.LowReject = 2.0 ' Reject outliers below 2.0 standard deviations
objSigmaCombine.DoCombine()
objSigmaCombine.WriteFITS("C:\MasterFrame.fit")
WScript.Echo("Images processed " & objSigmaCombine.
|