Re: Animated PNG



On Wed, 2009-04-08 at 11:52 +0200, Christian Schaubschlaeger wrote:
> Hello,
> 
> is it possible to display an animated PNG in an Gtk::Image object?
> Displaying an animated GIF works fine:
> 
> Gtk::Image *i;
> Glib::RefPtr <Gdk::PixbufAnimation> anim;
> 
> anim = Gdk::PixbufAnimation::create_from_file("anim.gif");
> i->set(m_anim);
> i->show();
> 
> However, if I use an animated PNG the image displayed is
> not animated at all.

I agree that would be nice, but it doesn't seem possible yet. I think
you need to iterate through the pixbufs in the PixbufAnimation and set
them in the Gtk::Image in sequence.

> If this is not possible, what options (besides animated GIF,
> which I don't like due to it's limited color space) do I have to display
> animated contents?

gstreammermm has a working video player example.

-- 
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com




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