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 43 44 45 46 47 48 49 50 51 52 53 54 55
|
.TH "gcpMapRGBAColor" 3 "2005-07-30" "libggigcp-1.0.x" GGI
.SH NAME
\fBgcpMapRGBAColor\fR, \fBgcpPackRGBAColors\fR, \fBgcpMapYUVColor\fR, \fBgcpPackYUVColors\fR, \fBgcpMapCMYKColor\fR, \fBgcpPackCMYKColors\fR, \fBgcpMapHSVColor\fR, \fBgcpPackHSVColors\fR, \fBgcpMapYCCColor\fR, \fBgcpPackYCCColors\fR : Convert from gcp_*color(s) to gcp_pixel(s)
.SH SYNOPSIS
.nb
.nf
#include <ggi/gcp.h>
gcp_pixel gcpMapRGBAColor(ggi_visual_t vis,
gcp_RGBAcolor *col);
int gcpPackRGBAColors(ggi_visual_t vis,
void *buf,gcp_RGBAcolor *cols,int len);
gcp_pixel gcpMapYUVColor(ggi_visual_t vis,
gcp_YUVcolor *col);
int gcpPackYUVColors(ggi_visual_t vis,
void *buf,gcp_YUVcolor *cols,int len);
gcp_pixel gcpMapCMYKColor(ggi_visual_t vis,
gcp_CMYKcolor *col);
int gcpPackCMYKColors(ggi_visual_t vis,
void *buf,gcp_CMYKcolor *cols,int len);
gcp_pixel gcpMapHSVColor(ggi_visual_t vis,
gcp_HSVcolor *col);
int gcpPackHSVColors(ggi_visual_t vis,
void *buf,gcp_HSVcolor *cols,int len);
gcp_pixel gcpMapYCCColor(ggi_visual_t vis,
gcp_YCCcolor *col);
int gcpPackYCCColors(ggi_visual_t vis,
void *buf,gcp_YCCcolor *cols,int len);
.fi
.SH DESCRIPTION
\fBgcpMap*Color\fR gets the pixelvalue for the given color.
\fBgcpPack*Colors\fR converts the colors in \fIcols\fR to pixelvalues in
\fIbuf\fR. The output from this function is suitable for input to the
\fBggiPut{HLine,VLine,Box}\fR functions.
Try to cache the results of color lookups in your application for
efficiency purposes.
.SH RETURN VALUE
\fBgcpMap*Color\fR returns a \f(CWgcp_pixel(3)\fR.
\fBgcp*PackColors\fR returns \fB0\fR for OK, otherwise an \f(CWggi-error(3)\fR code.
.SH SEE ALSO
\f(CWgcp_pixel(3)\fR,
\f(CWgcpUnmapRGBAPixel(3)\fR, \f(CWgcpUnpackRGBAPixels(3)\fR,
\f(CWgcpUnmapYUVPixel(3)\fR, \f(CWgcpUnpackYUVPixels(3)\fR,
\f(CWgcpUnmapCMYKPixel(3)\fR, \f(CWgcpUnpackCMYKPixels(3)\fR,
\f(CWgcpUnmapHSVPixel(3)\fR, \f(CWgcpUnpackHSVPixels(3)\fR,
\f(CWgcpUnmapYCCPixel(3)\fR, \f(CWgcpUnpackYCCPixels(3)\fR
\f(CWggiPutBox(3)\fR, \f(CWggiPutHLine(3)\fR, \f(CWggiPutVLine(3)\fR
|