Function Arguments
/*-***************************************************************************/ /* */ /* mViewer */ /* */ /* This program generates a JPEG image file from a FITS file (or a set */ /* of three FITS files in color). A data range for each image can */ /* be defined and the data can be stretch by any power of the log() */ /* function (including zero: linear). Pseudo-color color tables can */ /* be applied in single-image mode. */ /* */ /* Scaled symbols (individually or for a catalog table), image outlines, */ /* and labels (individually or from a table) and coordinate grids can be */ /* overlaid on the image. The details of the command syntax for this are */ /* too involved to document here. See the mViewer documentation on-line */ /* or delivered with the Montage source. */ /* */ /* int mode Type of the command string: 0 for argument list */ /* and 1 for JSON. */ /* */ /* char *cmdstr The command string (arguments or JSON) */ /* */ /* char *outFile Output PNG/JPEG */ /* char *outFmt "png" or "jpeg" */ /* */ /* int debug Debugging output level */ /* */ /*****************************************************************************/ struct mViewerReturn *mViewer(int mode, char *cmdstr, char *outFile, char *outFmt, int debugin)
Return Structure
struct mViewerReturn { int status; // Return status (0: OK, 1:ERROR) char msg [1024]; // Return message (for error return) char json[4096]; // Return parameters as JSON string char type[32]; // Whether the output is 'color' or 'grayscale' int nx; // Width of the image in pixels int ny; // Height of the image in pixels double grayminval; // Minimum stretch data value (grayscale) double grayminpercent; // Percentile level in histogram for min stretch value (gray) double grayminsigma; // 'Sigma' level in histogram for min stretch value (gray) double graymaxval; // Maximum stretch data value (grayscale) double graymaxpercent; // Percentile level in histogram for min stretch value (gray) double graymaxsigma; // 'Sigma' level in histogram for min stretch value (gray) double blueminval; // Minimum stretch data value (color: blue image) double blueminpercent; // Percentile level in histogram for min stretch value (blue) double blueminsigma; // 'Sigma' level in histogram for min stretch value (blue) double bluemaxval; // Maximum stretch data value (color: blue image) double bluemaxpercent; // Percentile level in histogram for max stretch value (blue) double bluemaxsigma; // 'Sigma' level in histogram for min stretch value (blue) double greenminval; // Minimum stretch data value (color: green image) double greenminpercent; // Percentile level in histogram for min stretch value (green) double greenminsigma; // 'Sigma' level in histogram for min stretch value (green) double greenmaxval; // Maximum stretch data value (color: green image) double greenmaxpercent; // Percentile level in histogram for max stretch value (green) double greenmaxsigma; // 'Sigma' level in histogram for min stretch value (green) double redminval; // Minimum stretch data value (color: red image) double redminpercent; // Percentile level in histogram for min stretch value (red) double redminsigma; // 'Sigma' level in histogram for min stretch value (red) double redmaxval; // Maximum stretch data value (color: red image) double redmaxpercent; // Percentile level in histogram for max stretch value (red) double redmaxsigma; // 'Sigma' level in histogram for min stretch value (red) double graydatamin; // Minimum data value for grayscale image double graydatamax; // Maximum data value for grayscale image double bdatamin; // Minimum data value for blue image double bdatamax; // Maximum data value for blue image double gdatamin; // Minimum data value for green image double gdatamax; // Maximum data value for green image double rdatamin; // Minimum data value for red image double rdatamax; // Maximum data value for red image int flipX; // Boolean: whether the image X axis was flipped int flipY; // Boolean: whether the image Y axis was flipped int colortable; // Grayscale: pseudo-color lookup table index char bunit[256]; // Flux units in data files (from BUNIT header keyword) };