Re: Gtk2::Gdk::Pixbuf on win32
- From: "T.J. Ferraro" <tjtoocool phreaker net>
- To: gtk-perl-list gnome org
- Subject: Re: Gtk2::Gdk::Pixbuf on win32
- Date: Sun, 02 Mar 2008 20:07:13 -0800
rahed wrote:
"T.J. Ferraro" <tjtoocool phreaker net> writes:
Which is the line: $pixbuf = Gtk2::Gdk::Pixbuf->new_from_file('image.bmp');
Instead of Gtk2::Gdk::Pixbuf I use:
Gtk2::Image->new_from_file('image.jpg');
Also tried your way but found Gtk2::Image works to my purpose. Now I
don't remember what was wrong with Pixbuf.
Well, for my purpose the bitmap image is already in memory. Which is why
I was using the pixbuf way because it has a new_from_data method whereas
Gtk2::Image does not. Which is a small performance hit when you have to
write something to disk only to read it again.
In any case, I figured I would give it a try right now. However, when I
use Gtk2::Image and pack it all I get is a small box with a red X.
Calling either get_pixbuf or get_image, gives me either:
Gtk-CRITICAL **: gtk_image_get_image: assertion `image->storage_type ==
GTK_IMAGE_IMAGE || image->storage_type == GTK_IMAGE_EMPTY'
Gtk-CRITICAL **: gtk_image_get_image: assertion `image->storage_type ==
GTK_IMAGE_IMAGE || image->storage_type == GTK_IMAGE_EMPTY'
Any other suggestions? Thanks.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]