PMHPackPixmap() -- Pack Native Format Pixmap

The PMHPackPixmap() function will take a three plan RGB image and reorganize it into a packed pixmap format.

See Also: PMHUnpackPixmap()

CALL SEQUENCE

uchar * PMHPackPixmap( psPreferPixmap, pbyRedData, pbyGreenData, 
                       pbyBlueData, nRGBWidth, nRGBHeight,
                       nXOff, nYOff, nWidth, nHeight );
PMHPreferPixmap *psPreferPixmap;
               Structure containing the information on how to pack the
               pixmap structure.
uchar      *pbyRedData;
               Red image data.
uchar      *pbyGreenData;
               Green image data.
uchar      *pbyBlueData;
               Blue image data.
int        nRGBWidth;
               The width of the images stored in pbyRedData, pbyGreenData
               and pbyBlueData.
int        nRGBHeight;
               The height of the images stored in pbyRedData, pbyGreenData,
               and pbyBlueData.
int        nXOff;
               The X offset into the source image to pack.
int        nYOff;
               The Y offset into the source image to pack.
int        nXSize;
               The width of the subarea to pack out of the source image.
int        nYSize;
               The height of the subarea to pack out of the source image.
The PMHPackPixmap() function returns a pointer to packed image data which can be deallocated with HFree().

PMHPreferPixmap

  typedef struct
  {
    int                 nBytesPerPixel;   
    int                 nDepth;           
    int                 nScanlinePad;     

    int                 nRedShift;       
    int                 nGreenShift;
    int                 nBlueShift;

    uchar               abyRedComp[256]; 
    uchar               abyGreenComp[256];
    uchar               abyBlueComp[256];
    uchar               abyGreyComp[256];
    uchar               abyMap8Index[256];

    TBool               bTopToBottom;     
    TBool               bUseCompress;     
    uchar*              paby8to24;
  } PMHPreferPixmap;

About PCI Help Gateway