[Previous] [Contents] [Index] [Next]

PgGetPalette()

Query for current color palette

Synopsis:

int PgGetPalette(PgColor_t *palette);

Description:

This function queries the graphics driver for the current palette. A palette is an array of _Pg_MAX_PALETTE (256) RGB colors. The palette parameter must be a pointer to a suitably-sized array, which will be filled with the color values representing the current palette.

This function is useful for graphical image utilities such as pv, which can perform improved dithering with knowledge of the graphics palette.

Returns:

0
Successful completion.
-1
An error occurred.

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

[Previous] [Contents] [Index] [Next]