# To subscribers of the xforms list from Angus Leeming <a.leeming@ic.ac.uk> :
To set an xforms color
int r, g, b /* 0 < r,g,b < 255 */
fl_mapcolor( FL_FREE_COL4, r, g, b );
To extract an xforms color
fl_getmcolor( FL_FREE_COL4, &r, &g, &b);
Angus
On Wednesday 15 November 2000 14:59, Yann Guichoux wrote:
> # To subscribers of the xforms list from Yann Guichoux
> <yann.guichoux@ago.fr> :
>
> Hi,
>
> does anyone know the way to get an rgb triplet (from the xforms internal
> colormap) corresponding to a pixel value (obtained with XGetPixel()) ?
> (whatever the visual depth is...(8,16,24,32 bits))
> or to know the color indice in the xforms colormap corresponding to this
> pixel value.
> (there is a fl_get_pixel(FL_COLOR) function...is there a simple way to
> make a "fl_get_colorIndice(unsigned long Pixel)" function ???)
>
> thanks for any help.
>
> Yann
> _________________________________________________
> To unsubscribe, send the message "unsubscribe" to
> xforms-request@bob.usuhs.mil or see
> http://bob.usuhs.mil/mailserv/xforms.html
> XForms Home Page: http://world.std.com/~xforms
> List Archive: http://bob.usuhs.mil/mailserv/list-archives/
_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuhs.mil or see
http://bob.usuhs.mil/mailserv/xforms.html
XForms Home Page: http://world.std.com/~xforms
List Archive: http://bob.usuhs.mil/mailserv/list-archives/
This archive was generated by hypermail 2b29 : Thu Nov 16 2000 - 11:58:54 EST