XForms: Internal ColorMap and XCreateImage and XPutImage!!!!

Christian Faraoni (mago@caronte.csr.unibo.it)
Thu, 05 Feb 1998 17:46:13 +0100

# To subscribers of the xforms list from Christian Faraoni <mago@caronte.csr.unibo.it> :

Hello, I have a question for you.

Can I use the internal ColorMap with XCreateImage and XPutImage (using a
Free Object)???

I have an array of 256x256 elements (the range = 0 - 255) and I would
allocate an XImage using
the internal ColorMap Xform. How can I do it?

I did it already, with canvas... I assigned the XWin DefaultColorMap to
the canvas, as follows:

Display *DDisplay;
Colormap Dcolormap;
.
.
.
DDisplay=FL_FormDisplay(Fd_s_gall);
Dcolormap=XDefaultColormap(DDisplay,DefaultScreen(DDisplay));
fl_set_canvas_colormap(Fd_s_gall->Slide,Dcolormap);

and then I allocated 256 grey levels in the ColorMap.
Therefore, my main problem is how to do the same thing without the use
of canvas, using
Free Object instead.

thanks a lot. The Magician

--
Faraoni Cristian

_________________________________________________ To unsubscribe, send the message "unsubscribe" to xforms-request@bob.usuf2.usuhs.mil or see http://bob.usuf2.usuhs.mil/mailserv/xforms.html XForms Home Page: http://bloch.phys.uwm.edu/xforms List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/