Re: GdkPixbufAnimation get number of frames ?



On 02 Oct 2002 07:55:16 -0400, Owen Taylor wrote:
> 
> torben hohn <torbenh gmx de> writes:
> 
> > in the current implementation i can not obtain the number of
> > frames in a gif animation.
> > it always loops.
> > 
> > so i can not do 
> > while( gdk_pixbuf_animation_iter_get_delay_time( iter ) != -1 )
> >   put frame into GList and advace iter
> > 
> > I think there should be a property on the iter which can control the
> > loop
> > behaviour. (obeying the loop flag on the animation would not work
> > for me because then loading a looping animation into a GList would
> > cause an infinite loop.
> 
> Not really answering your question, but the idea of trying to get all
> the frames in an animation by stepping it and recording each frame has
> a problem - GdkPixbufAnimation is not frame based. You can have
> animation formats with elements that move continuously in time (MNG
> allows this, if I'm not mistaken.) In such cases, you could
> end up with a huge amount of generated data.

i only need that for gifs and with gifs and the 
gdk_pixbuf_animation_iter_on_currently_loading_frame()
function returning TRUE on the last frame, it is possible to do that.


> 
> The suggested API addition in:
> 
>  http://bugzilla.gnome.org/show_bug.cgi?id=65902
> 
> Would allow getting an array of all the frames in
> a GIF or ANI animation.

I only had a quick glance on the page (did not look at the patches)
this looks like a good idea to implement the animation with a collection
as base.

i dont want to be dependent on gtk+2.2 a the Moment.
(i just ported to 2.0)
For my purposes the gdk-pixbuf Interface of 2.0 is sufficient.

Thanks for your help.


> 
> Regards,
>                                         Owen
> _______________________________________________
> gtk-devel-list mailing list
> gtk-devel-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-devel-list
> 




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