Bits-Per-Pixel Constants
Syntax
CImage::BPP16
CImage::BPP32
Type
const static int
Required Headers
CImage.h
Remarks
Integer class constants that correspond to the bits-per-pixel used in the image.

NAME DESCRIPTION VALUE
BPP16 16-bit image data 16
BPP32 32-bit image data 32
Example
        // This code demonstrates how to print out the
        // histogram for a 32-bit image.

        #include <iostream>
        #include "CController.h"
        #include "CImage.h"

        using namespace std;
        using namespace arc;

        int main()
        {
           CController cController;
           CImage cImg;

           try {
                // ....
                //
                // Take an image, which will reside in the kernel
                // image buffer ( cController.mapFd )
                //
                // ....

                //
                // Assumes a 512x600 pixel image was taken and resides
                // in the kernel image buffer ( cController.mapFd )
                //
                long lHistSize = 0;

                long *pHist = cImg.Histogram( &lHistSize,
                                              cController.mapFd,
                                              512,
                                              600,
                                              CImage::BPP32 );

                for ( long i=0; i<lHistSize; i++ )
                    cout << "hist[ " << i << " ]: " << pHist[ i ] << endl;

                cImg.FreeHistogram();
            }
            catch ( std::exception &e )
            {
                cImg.FreeHistogram();
                cerr << "Exception Occurred: " << e.what() << endl;
            }
        }

© Astronomical Research Cameras, Inc.