GdkPixbuf animation
Hi all, I have noticed that there is a way to load an animation using gdk_pixbuf_animation_new_from_file. But is there a way to save already loaded/created animation to a file? For example GdkPixbuf has a method gdk_pixbuf_save Thanks in advance, Tomas Soltys ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
runtime version symbols (was Re: gdkpixbuf-animation: how to play without looping)
[EMAIL PROTECTED] ha scritto: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, Sep 26, 2006 at 06:45:22PM +0200, Francesco Montorsi wrote: Hi, I need to play a GdkPixbufAnimation without looping it. I.e. after the last frame is displayed, I do *not* want to display the first frame again... I don't know (at compile-time) which animation my program will need to play so I don't know its frame count and GdkPixbufAnimation won't let me know that. How can I do ? AFAIK, the animated image itself contains the intended delays for each frame (but I'm no expert here, so take with a pound of salt). yes, right. However GdkPixbufAnimation and its iter_advance() function will automatically restart the animation when the delay of the last frame has elapsed... that is, there's no way to avoid looping it currently. On the other hand, some query functions into the structure of the animation would be nice here. right. I submitted a patch which adds _get_frame_count and _get_current_frame functions to GdkPixbufAnimation. However, I've now another small conceptual problem now: consider the following code: printf(compiled against gdk-pixbuf %s\n, GDK_PIXBUF_VERSION); printf(linked against gdk-pixbuf %s\n\n, gdk_pixbuf_version); if I dynamically link my program on my linux which has e.g. gdk-pixbuf version 2.10.3 installed, and then run that binary on another linux which has gdk-pixbuf 2.8 installed, will I get compiled against gdk-pixbuf 2.10.3 linked against gdk-pixbuf 2.8.0 or rather: compiled against gdk-pixbuf 2.10.3 linked against gdk-pixbuf 2.10.3 ? I think the first: i.e. gdk_pixbuf_version contains the version of the dynamically loaded library, but I just want to be sure... Thanks, Francesco Montorsi Chiacchiera con i tuoi amici in tempo reale! http://it.yahoo.com/mail_it/foot/*http://it.messenger.yahoo.com ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: runtime version symbols (was Re: gdkpixbuf-animation: how to play without looping)
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Sep 28, 2006 at 12:13:03PM +0200, Francesco Montorsi wrote: [EMAIL PROTECTED] ha scritto: [...] yes, right. However GdkPixbufAnimation and its iter_advance() function will automatically restart the animation when the delay of the last frame has elapsed... that is, there's no way to avoid looping it currently. On the other hand, some query functions into the structure of the animation would be nice here. right. I submitted a patch which adds _get_frame_count and _get_current_frame functions to GdkPixbufAnimation. Maybe there are animations where the concept of frame count doesn't make sense? However, I've now another small conceptual problem now: consider the following code: printf(compiled against gdk-pixbuf %s\n, GDK_PIXBUF_VERSION); printf(linked against gdk-pixbuf %s\n\n, gdk_pixbuf_version); if I dynamically link my program on my linux which has e.g. gdk-pixbuf version 2.10.3 installed, and then run that binary on another linux which has gdk-pixbuf 2.8 installed, will I get compiled against gdk-pixbuf 2.10.3 linked against gdk-pixbuf 2.8.0 or rather: compiled against gdk-pixbuf 2.10.3 linked against gdk-pixbuf 2.10.3 ? I think the first: i.e. gdk_pixbuf_version contains the version of the dynamically loaded library, but I just want to be sure... According to the docs it should be the first: gdk_pixbuf_version is an external variable which lives in the lib (so it should reflect the lib's version) while GDK_PIXBUF_VERSION is a C preprocessor macro which gets burnt into your code at compile time. Regards - -- tomas -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFFG6GdBcgs9XrR2kYRAldDAJ9EyopcTrLvyJJdrfcTSbGjqZkEogCggkwi piDuLSU8XVJzXz7+1gl5F60= =e7KI -END PGP SIGNATURE- ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: runtime version symbols (was Re: gdkpixbuf-animation: how to play without looping)
[EMAIL PROTECTED] ha scritto: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Sep 28, 2006 at 12:13:03PM +0200, Francesco Montorsi wrote: [EMAIL PROTECTED] ha scritto: [...] yes, right. However GdkPixbufAnimation and its iter_advance() function will automatically restart the animation when the delay of the last frame has elapsed... that is, there's no way to avoid looping it currently. On the other hand, some query functions into the structure of the animation would be nice here. right. I submitted a patch which adds _get_frame_count and _get_current_frame functions to GdkPixbufAnimation. Maybe there are animations where the concept of frame count doesn't make sense? currently there's none (gdk-pixbuf currently supports GIF and ANI animated formats only); in future some formats, e.g animated SVG, may give some problem to the frame concept. However the frame concept is already implied by gdkpixbuf API and in particular by gdk_pixbuf_animation_iter_advance(). In fact this function returns TRUE if the animation needs update, i.e. if a new frame must be displayed. However, I've now another small conceptual problem now: consider the following code: printf(compiled against gdk-pixbuf %s\n, GDK_PIXBUF_VERSION); printf(linked against gdk-pixbuf %s\n\n, gdk_pixbuf_version); if I dynamically link my program on my linux which has e.g. gdk-pixbuf version 2.10.3 installed, and then run that binary on another linux which has gdk-pixbuf 2.8 installed, will I get compiled against gdk-pixbuf 2.10.3 linked against gdk-pixbuf 2.8.0 or rather: compiled against gdk-pixbuf 2.10.3 linked against gdk-pixbuf 2.10.3 ? I think the first: i.e. gdk_pixbuf_version contains the version of the dynamically loaded library, but I just want to be sure... According to the docs it should be the first: gdk_pixbuf_version is an external variable which lives in the lib (so it should reflect the lib's version) while GDK_PIXBUF_VERSION is a C preprocessor macro which gets burnt into your code at compile time. Ok, thanks for the confirmation. Thanks, Francesco Chiacchiera con i tuoi amici in tempo reale! http://it.yahoo.com/mail_it/foot/*http://it.messenger.yahoo.com ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: runtime version symbols (was Re: gdkpixbuf-animation: how to play without looping)
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Sep 28, 2006 at 03:11:03PM +0200, Francesco Montorsi wrote: [EMAIL PROTECTED] ha scritto: [...] Maybe there are animations where the concept of frame count doesn't make sense? currently there's none (gdk-pixbuf currently supports GIF and ANI animated formats only); in future some formats, e.g animated SVG, may give some problem to the frame concept. However the frame concept is already implied by gdkpixbuf API and in particular by gdk_pixbuf_animation_iter_advance(). Yes, right -- in the sense of discrete time steps. But there might be infinitely many (or indefinitely many ;). Let me contrive an example: a mechanical simulation af a five-body problem with chaos and all that. [...VERSION vs ...version] According to the docs it should be the first[...] Ok, thanks for the confirmation. Note that I didn't actually try it :-) Regards - -- tomas -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFFHJ46Bcgs9XrR2kYRAqgSAJ4g9bco2Xd1fUfr5nMKpwwb5elpaACfd9yw 5REMYsWv6RxqOV+r0qF4WUg= =mHtv -END PGP SIGNATURE- ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
gdkpixbuf-animation: how to play without looping
Hi, I need to play a GdkPixbufAnimation without looping it. I.e. after the last frame is displayed, I do *not* want to display the first frame again... I don't know (at compile-time) which animation my program will need to play so I don't know its frame count and GdkPixbufAnimation won't let me know that. How can I do ? Thanks a lot, Francesco Montorsi Chiacchiera con i tuoi amici in tempo reale! http://it.yahoo.com/mail_it/foot/*http://it.messenger.yahoo.com ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: gdkpixbuf-animation: how to play without looping
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, Sep 26, 2006 at 06:45:22PM +0200, Francesco Montorsi wrote: Hi, I need to play a GdkPixbufAnimation without looping it. I.e. after the last frame is displayed, I do *not* want to display the first frame again... I don't know (at compile-time) which animation my program will need to play so I don't know its frame count and GdkPixbufAnimation won't let me know that. How can I do ? AFAIK, the animated image itself contains the intended delays for each frame (but I'm no expert here, so take with a pound of salt). On the other hand, some query functions into the structure of the animation would be nice here. Regards - -- tomas -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQFFGgAmBcgs9XrR2kYRArQpAJ9J43FAovVmzkeKa7eOH6koRgeEaQCeIzfv KCXsb76aTcbcTQjZ2Th89eg= =tRK4 -END PGP SIGNATURE- ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list