Export (0) Print
Expand All
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

PALETTEINDEX2BPP

Windows Mobile 6.5
A version of this page is also available for
4/8/2010

The PALETTEINDEX2BPP macro accepts an index to a logical-color palette entry and returns a palette-entry specifier consisting of a COLORREF value that specifies the color associated with the given index. An application using a logical palette can pass this specifier, instead of an explicit red, green, blue (RGB) value, to GDI functions that expect a color. This allows the function to use the color in the specified palette entry.


#define PALETTEINDEX2BPP (i) \
                       (((i)==0)?0x00000000: \
                       (((i)==1)?0x00808080: \
                       (((i)==2)?0x00C0C0C0:0x00FFFFFF)))

i

Specifies an index to the palette entry containing the color to be used for a graphics operation.

The return value is a logical-palette index specifier.

Headerwindows.h
Windows Embedded CEWindows CE 1.0 and later
Windows MobileWindows Mobile Version 5.0 and later

Community Additions

Show:
© 2014 Microsoft