Re: [gtk-list] How to draw images quickly?
- From: Havoc Pennington <hp redhat com>
- To: GTK Liste <gtk-list redhat com>
- Subject: Re: [gtk-list] How to draw images quickly?
- Date: Tue, 7 Dec 1999 11:25:09 -0500 (EST)
On Tue, 7 Dec 1999, Nils Rennebarth wrote:
> In my application one window continually shows the image got from a
> framegrabber. It's 565x480 pixel big and the framegrabber already delivers
> it in the format the X server will need it, i.e. it only works with an X
> True Color or Direct Color Display of 32bit depth, which is ok for us.
>
In that case, you probably want to just dump the stuff to an XImage
(GdkImage). The Xlib book (by Adrian Nye) is about the only place with the
necessary details.
> What is the recommended and fastest method to display this image? No
> dithering or conversion needs to be done. Would gdk_draw_rgb_32_image
> do the right thing?
IIRC gdk_draw_rgb_32_image() will draw data in the format
red-green-blue-padding, where each of rgbp is one byte. If you have this
format, then the function will work, but if you're already in GdkImage
format then probably it's faster to use that.
Havoc
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]