| CLASS MEMBER | TYPE | DESCRIPTION |
| cImg1Stats | CImgStats | Image statistics for the first flat image |
| cImg2Stats | CImgStats | Image statistics for the second flat image |
| cImgDiffStats | CImgStats | Image statistics for the difference between the flat images |
// This code demonstrates how to print out the difference
// stats for two flat field images over the entire image.
#include <iostream>
#include "CImage.h"
using namespace std;
using namespace arc;
int main()
{
unsigned short *pBuf1 = NULL;
unsigned short *pBuf2 = NULL;
//
// Assign pBuf1/2 pointers to image data that
// can be directly from a camera or from an
// existing FITS file, etc.
//
// .....
try {
CImage cImg;
//
// pBuf1 & 2 represent image buffers that contain
// 1024x1200 pixel images.
//
CImage::CImgDifStats cDifStats = cImg.GetDiffStats( pBuf1,
pBuf2,
1024,
1200 );
cout << "pBuf1 min: " << cDifStats.cImg1Stats.gMin
<< "pBuf1 max: " << cDifStats.cImg1Stats.gMax << endl;
cout << "pBuf2 min: " << cDifStats.cImg2Stats.gMin
<< "pBuf2 max: " << cDifStats.cImg2Stats.gMax << endl;
cout << "Diff min: " << cDifStats.cImgDiffStats.gMin
<< "Diff max: " << cDifStats.cImgDiffStats.gMax << endl;
}
catch ( std::exception &e )
{
cerr << "Exception Occurred: " << e.what() << endl;
}
}
© Astronomical Research Cameras, Inc.