how to zoom a pixmap containing symbols
- From: WEBER Luc <Luc Weber obs unige ch>
- To: gtk-app-devel-list gnome org
- Subject: how to zoom a pixmap containing symbols
- Date: Wed, 23 Jan 2002 09:02:05 +0100 (MET)
I'm trying to zoom a pixmap. The pixmap contains a 8 bits image greyscale and a
lot of symboles or text strings. I want to zoom the image, the symbols and the
for the construction of the image I do:
gc, x, y, npix_x, npix_y, dith,
font, gc, x, y, msg ,strlen(msg));
gc, x, y);
The display is made with
0, 0, 0, 0, npix_x, npix_y);
At this point, all is perfect, I have my own 'cmap' and all works very well.
But for the zoom, I get a part of the pixmap in a GdkImage with:
image = gdk_image_get(pixmap,
and after, I get each pixel of the GdkImage with:
pixel = gdk_image_get_pixel(image, i, j);
And now the problem is:
What can I do with this pixel (guint32), it contains the good
RGB information (it seems), but if I zoom it with:
what shall I put in the gc foreground value to obtain then same
color I had in the original display (with my 'cmap')?
The aim of this program is to display CCD image, or FITS files (both in grey
values) in false color. I have a lot of cmap and I want to display the original
image with different cut levels, with different cmap, put symbols on the image
and finaly zoom part of the image situated under the mouse pointer.
This program acts also like a server and receive commands from socket. The last
problem was: how to zoom the image and visualize the symboles drawn on the
Thanks a lot if you have a answer. May be I'm complety on a wrong way, but it's
really the only last problem.....
] [Thread Prev