Re: Byte array to Image

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2009-06-26 at 18:45 +0100, António Pinho wrote:
> Hi there! I have a byte array that is data from an image.. how can i> turn that array of bytes into a jpeg or bmp image file?
If your byte array image data is in RGB format, you can create aGdkPixbuf from it using
http://library.gnome.org/devel/gdk-pixbuf/stable/gdk-pixbuf-creating.html#gdk-pixbuf-new-from-data
and then use gdk_pixbuf_save() to save it as jpeg:
http://library.gnome.org/devel/gdk-pixbuf/stable/gdk-pixbuf-file-saving.html#gdk-pixbuf-save
 Cheers  -Tim
_______________________________________________gtk-list mailing listgtk-list@xxxxxxxxxxxxx://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux