UINT GetPaletteEntries(hpal, iStart, cEntries, lppe) | |||||
HPALETTE hpal; | /* handle of palette, */ | ||||
UINT iStart; | /* first palette entry to retrieve | */ | |||
UINT cEntries; | /* number of entries to retrieve | */ | |||
PALETTEENTRY FAR* lppe; | /* address of structure for palette entries | */ |
The GetPaletteEntries function retrieves a range of palette entries in a logical palette.
hpal
Identifies the logical palette.
iStart
Specifies the first logical-palette entry to be retrieved.
cEntries
Specifies the number of logical-palette entries to be retrieved.
lppe
Points to an array of PALETTEENTRY structures that will receive the palette entries. The array must contain at least as many structures as specified by the cEntries parameter. The PALETTEENTRY structure has the following form:
typedef struct tagPALETTEENTRY { /* pe */
BYTE peRed;
BYTE peGreen;
BYTE peBlue;
BYTE peFlags;
} PALETTEENTRY;
For a full description of this structure, see the Microsoft Windows Programmer's Reference, Volume 3.
The return value is the number of entries retrieved from the logical palette, if the function is successful. Otherwise, it is zero.