Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize

SetDIBColorTable (Windows CE 5.0)

Windows CE 5.0
Send Feedback

This function sets red, green, and blue color values in a range of entries in the color table of the DIB that is currently selected into a specified device context.

WINGDIAPI UINT WINAPI SetDIBColorTable(
  HDC hdc,
  UINT uStartIndex,
  UINT cEntries,
  CONST RGBQUAD* pColor
);

Parameters

hdc
[in] Handle to a device context.

A DIB must be selected into this device context.

uStartIndex
[in] Unsigned integer that that specifies a zero-based index of the first color table entry that you want to set.
cEntries
[in] Unsigned integer that specifies the number of color table entries that you want to set.
pColor
[in] Pointer to an array of RGBQUAD structures that contain new color information for the color table of the DIB.

Return Values

The number of color table entries that the function sets indicates success.

Zero indicates failure.

To get extended error information, call GetLastError.

Remarks

Call SetDIBColorTable to set the color table for DIBs that use 1, 4, or 8 bpp.

The biBitCount member of the BITMAPINFOHEADER structure that corresponds to a bitmap specifies the number of bpp.

Device-independent bitmaps that have a biBitCount value greater than 8 do not have a color table.

Requirements

OS Versions: Windows CE .NET 4.0 and later.
Header: Windows.h.
Link Library: Coredll.lib.

See Also

CreateDIBSection | GetDIBColorTable | GetObject | BITMAPINFOHEADER | DIBSECTION | RGBQUAD


Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.


Show:
© 2015 Microsoft