File: ggiSetPalette.3ggi

package info (click to toggle)
libggi 1%3A2.0.1-2
  • links: PTS
  • area: main
  • in suites: woody
  • size: 6,072 kB
  • ctags: 5,274
  • sloc: ansic: 42,720; sh: 6,508; makefile: 666
file content (42 lines) | stat: -rw-r--r-- 1,496 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
.\\" auto-generated by docbook2man-spec $Revision: 1.5 $
.TH "ggiSetPalette" "3ggi" "22 August 2001" "GGI" "LibGGI API"
.SH NAME
ggiSetPalette, ggiGetPalette \- Manipulate the palette of a visual
.SH SYNOPSIS
\fB#include <ggi/ggi.h>
.sp
int ggiGetPalette(ggi_visual_t \fIvis\fB, 
int \fIs\fB, 
int \fIlen\fB, 
ggi_color *\fIcmap\fB);
.sp
int ggiSetPalette(ggi_visual_t \fIvis\fB, 
int \fIs\fB, 
int \fIlen\fB, 
ggi_color *\fIcmap\fB);
\fR.SH "DESCRIPTION"
.PP
LibGGI visuals in \fBGT_PALETTE\fR mode maps all pixelvalues to the
corresponding \fBggi_color\fR entry in the visual's palette.
.PP
\fBggiSetPalette\fR sets a range of palette values, of length
\fIlen\fR, starting at index number \fIs\fR. The index can be
\fBGGI_PALETTE_DONTCARE\fR to indicate to indicate that the palette can be
installed anywhere in the CLUT.
This allows optimised use in windowing environments (to minimize color
flashing between windows) and should be used if possible.
.PP
\fBggiGetPalette\fR copies the specified colors (starting from
\fIs\fR, for \fIlen\fR colors) from the visual's palette to the array
pointed by \fIcmap\fR.
.SH "RETURN VALUE"
.PP
\fBggiSetPalette\fR returns the number of the first entry
changed. Negative values indicate error (codes). 
.PP
\fBggiGetPalette\fR returns 0 for OK, otherwise
an error code. When called with len=0 this function will not
automatically succeed, but the return code will indicate whether there
is a readable CLUT. 
.SH "SEE ALSO"
[XRef to GGISETCOLORFULPALETTE]