C-Munipack 1.2 / Application programming interface / API reference
C-Munipack 1.2 / Application programming interface / API reference
CmpackKombine | Output frame context for kombine tool. |
cmpack_kombine_init | Make new kombine context. |
cmpack_kombine_set_console | Attach console to the context. |
cmpack_kombine_set_bitpix | Set output data format. |
cmpack_kombine_get_bitpix | Get output data format. |
cmpack_kombine_set_border | Set image border size. |
cmpack_kombine_get_border | Get image flip flags. |
cmpack_kombine_open | Open output file. |
cmpack_kombine_read | Add a frame to the accumulation buffer. |
cmpack_kombine_close | Make combined CCD frame and writes it to the file. |
Set of functions defined in this module allows user to merge (combine) a set of CCD frames.
Output frame context for kombine tool.
typedef struct _CmpackKombine CmpackKombine
This private data structure holds the accumulated data for single output frame.
Make new kombine context.
CmpackKombine * cmpack_kombine_init (void)
The reference counter is set to one. The caller is responsible to call cmpack_unref() when it is no longer needed.
pointer to new kombine context or zero on failure
Attach console to the context.
void cmpack_kombine_set_console (CmpackKombine * ctx, CmpackConsole * con)
Increment console's reference counter. Only one console can be attached to a single context. If another console is attached, by calling this function dettaches it. Set console to NULL to dettach the current console.
ctx | [in] | kombine context |
con | [in] | console context |
Set output data format.
void cmpack_kombine_set_bitpix (CmpackKombine * ctx, CmpackBitpix bitpix)
ctx | [in] | output file context |
bitpix | [in] | output data format |
zero on success or error code on failure
Get output data format.
CmpackBitpix cmpack_kombine_get_bitpix (CmpackKombine * ctx)
ctx | [in] | output file context |
output data format
Set image border size.
void cmpack_kombine_set_border (CmpackKombine * ctx, const CmpackBorder * border)
If you set the border to nonzero size, the conversion function will set the pixels which belongs to the border area to zero. You can use this feature to clear an unusable part of a frame.
ctx | [in] | conversion context |
border | [in] | border size in pixels |
Get image flip flags.
void cmpack_kombine_get_border (CmpackKombine * ctx, CmpackBorder * border)
ctx | [in] | conversion context |
border | [out] | border size in pixels |
Open output file.
int cmpack_kombine_open (CmpackKombine * ctx, CmpackCcdFile * outfile)
Opens new combined frame. Close the file by calling the cmpack_kombine_close() function.
ctx | [in] | kombine context |
outfile | [in] | output file context |
zero on success or error code on failure.
Add a frame to the accumulation buffer.
int cmpack_kombine_read (CmpackKombine * ctx, CmpackCcdFile * ccdfile, CmpackPhtFile * phtfile)
The function reads the frame from specified CCD-frame file. It reads also the position offset from specified photometry file. Then shifts the frame by the offset and adds it to the accumulation buffer.
ctx | [in] | kombine context |
ccdfile | [in] | CCD frame file |
phtfile | [in] | photometry file |
zero on success or error code on failure.
Make combined CCD frame and writes it to the file.
int cmpack_kombine_close (CmpackKombine * ctx)
The function computes the output CCD data, writes it to the file, closes the output frame.
ctx | [in] | kombine context |
zero on success or error code on failure.