Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes
MONOBITMAPINFO Struct Reference

List of all members.

Public Member Functions

 operator PBITMAPINFO2 ()
 operator PBITMAPINFOHEADER2 ()
 MONOBITMAPINFO (PBITMAPINFO2 pBI)
 MONOBITMAPINFO (LONG aWidth, LONG aHeight)

Public Attributes

BITMAPINFOHEADER2 bmpInfo
RGB2 argbColor [2]
BITMAPINFOHEADER bmiHeader
RGBQUAD bmiColors [2]

Detailed Description

Definition at line 79 of file nsImageOS2.cpp.


Constructor & Destructor Documentation

MONOBITMAPINFO::MONOBITMAPINFO ( PBITMAPINFO2  pBI) [inline]

Definition at line 87 of file nsImageOS2.cpp.

   {
      memcpy( &bmpInfo, pBI, sizeof( BITMAPINFOHEADER2));
      bmpInfo.cBitCount = 1;

      argbColor [0].bRed      = 0;
      argbColor [0].bGreen    = 0;
      argbColor [0].bBlue     = 0;
      argbColor [0].fcOptions = 0;
      argbColor [1].bRed      = 255;
      argbColor [1].bGreen    = 255;
      argbColor [1].bBlue     = 255;
      argbColor [1].fcOptions = 0;
   }

Here is the call graph for this function:

MONOBITMAPINFO::MONOBITMAPINFO ( LONG  aWidth,
LONG  aHeight 
) [inline]

Definition at line 289 of file nsImageWin.cpp.

  {
    memset(&bmiHeader, 0, sizeof(bmiHeader));
    bmiHeader.biSize = sizeof(BITMAPINFOHEADER);
    bmiHeader.biWidth = aWidth;
    bmiHeader.biHeight = aHeight;
    bmiHeader.biPlanes = 1;
    bmiHeader.biBitCount = 1;


    // Note that the palette is being set up so the DIB and the DDB have white and
    // black reversed. This is because we need the mask to have 0 for the opaque
    // pixels of the image, and 1 for the transparent pixels. This way the SRCAND
    // operation sets the opaque pixels to 0, and leaves the transparent pixels
    // undisturbed
    bmiColors[0].rgbBlue = 255;
    bmiColors[0].rgbGreen = 255;
    bmiColors[0].rgbRed = 255;
    bmiColors[0].rgbReserved = 0;
    bmiColors[1].rgbBlue = 0;
    bmiColors[1].rgbGreen = 0;
    bmiColors[1].rgbRed = 0;
    bmiColors[1].rgbReserved = 0;
  }

Here is the call graph for this function:


Member Function Documentation

MONOBITMAPINFO::operator PBITMAPINFO2 ( ) [inline]

Definition at line 84 of file nsImageOS2.cpp.

{ return (PBITMAPINFO2) &bmpInfo; }
MONOBITMAPINFO::operator PBITMAPINFOHEADER2 ( ) [inline]

Definition at line 85 of file nsImageOS2.cpp.

{ return &bmpInfo; }

Member Data Documentation

Definition at line 82 of file nsImageOS2.cpp.

Definition at line 286 of file nsImageWin.cpp.

BITMAPINFOHEADER MONOBITMAPINFO::bmiHeader

Definition at line 285 of file nsImageWin.cpp.

BITMAPINFOHEADER2 MONOBITMAPINFO::bmpInfo

Definition at line 81 of file nsImageOS2.cpp.


The documentation for this struct was generated from the following files: