Hi
I tryed to open an animated gif but info.NumberOfImages returns always 1 so I dunno how many frames are stored into it and about the framerate... how do I know the speed of the animation? maybe for animated gif is there a standard I don't know of?
Best regards.
Problems reading animated gif
Moderators: XnTriq, helmut, xnview
-
- Author of XnView
- Posts: 44917
- Joined: Mon Oct 13, 2003 7:31 am
- Location: France
Re: Problems reading animated gif
Currrently not possible to know the frame rate. And for gif animated, there is a little problem, try gflLoadBitmap and you'll have a NumberOfImages not 1Alessandro wrote:I tryed to open an animated gif but info.NumberOfImages returns always 1 so I dunno how many frames are stored into it and about the framerate... how do I know the speed of the animation? maybe for animated gif is there a standard I don't know of?
Pierre.
-
- Posts: 2
- Joined: Thu Nov 30, 2006 10:37 am
- Location: Belgrade
How to extract other frames?
When I convert gif to some other format, I got only first frame. How to access (and save) other?
-
- Author of XnView
- Posts: 44917
- Joined: Mon Oct 13, 2003 7:31 am
- Location: France
Re: How to extract other frames?
You have GFL_LOAD_PARAMS::ImageWantedvoja21 wrote:When I convert gif to some other format, I got only first frame. How to access (and save) other?
Pierre.
-
- Posts: 16
- Joined: Sat Oct 03, 2009 10:17 am
- Location: Ukraine
Re: Problems reading animated gif
Is there any method to determine value of "Background Color Index" for whole gif and "Disposal Method" and "Delay" fields for pictures in animated gif? Pictures itself reads correctly, but I can't find out how to get this fields
-
- Posts: 16
- Joined: Sat Oct 03, 2009 10:17 am
- Location: Ukraine
Re: Problems reading animated gif
And there is another problem. I'm trying to load animated gif with about a three hundreds of frames. It is not quite big - about 60k, but it loads several seconds. As i call to load evety frame individually, the library, as I suppose, must again and again load and decode file from the beginning. Maybe there is wokaround?
-
- Author of XnView
- Posts: 44917
- Joined: Mon Oct 13, 2003 7:31 am
- Location: France
Re: Problems reading animated gif
No sorrylazyeugene wrote:Is there any method to determine value of "Background Color Index" for whole gif and "Disposal Method" and "Delay" fields for pictures in animated gif? Pictures itself reads correctly, but I can't find out how to get this fields
The problem is that GFL need to decompress all previous frames...lazyeugene wrote:And there is another problem. I'm trying to load animated gif with about a three hundreds of frames. It is not quite big - about 60k, but it loads several seconds. As i call to load evety frame individually, the library, as I suppose, must again and again load and decode file from the beginning. Maybe there is wokaround?
Pierre.
-
- Posts: 16
- Joined: Sat Oct 03, 2009 10:17 am
- Location: Ukraine
Re: Problems reading animated gif
But adding this fields to GFL_BITMAP structure should not be a problem, isn't it?xnview wrote:No sorrylazyeugene wrote:Is there any method to determine value of "Background Color Index" for whole gif and "Disposal Method" and "Delay" fields for pictures in animated gif? Pictures itself reads correctly, but I can't find out how to get this fields
Maybe you can register some kind of GFL_BITMAP array[]? Or save a pointer to next picture (offset from the begining of file) in GFL_BITMAP structure and accept it in load bitmap requests?xnview wrote:The problem is that GFL need to decompress all previous frames...lazyeugene wrote:And there is another problem. I'm trying to load animated gif with about a three hundreds of frames. It is not quite big - about 60k, but it loads several seconds. As i call to load evety frame individually, the library, as I suppose, must again and again load and decode file from the beginning. Maybe there is wokaround?
This is just a few fields, but without them it is almost unreal to load animated gif's. Please...
-
- Author of XnView
- Posts: 44917
- Joined: Mon Oct 13, 2003 7:31 am
- Location: France
Re: Problems reading animated gif
No, the better way is to add a function to load all bitmap from animated file
Pierre.
-
- Posts: 16
- Joined: Sat Oct 03, 2009 10:17 am
- Location: Ukraine
Re: Problems reading animated gif
I'll be waiting for a new version, thank you.