问题
In C#, I can get the individual frames from a gif and show the animation easily enough, but how do you go about getting the timing information for each frame?
回答1:
PropertyItem item = img.GetPropertyItem (0x5100); // FrameDelay in libgdiplus
// Time is in milliseconds
delay = (item.Value [0] + item.Value [1] * 256) * 10;
This article may be useful.
来源:https://stackoverflow.com/questions/3785031/getting-the-frame-duration-of-an-animated-gif