Bugfix for loopCount (#2155)

If a GIF image has no Netscape 2.0 loop extension, it is meant to play once and then stop
This commit is contained in:
线程 2018-01-09 21:59:30 +08:00 committed by DreamPiggy
parent 61703fced0
commit a6c0570987
1 changed files with 1 additions and 1 deletions

View File

@ -72,7 +72,7 @@
[frames addObject:frame];
}
NSUInteger loopCount = 0;
NSUInteger loopCount = 1;
NSDictionary *imageProperties = (__bridge_transfer NSDictionary *)CGImageSourceCopyProperties(source, nil);
NSDictionary *gifProperties = [imageProperties valueForKey:(__bridge_transfer NSString *)kCGImagePropertyGIFDictionary];
if (gifProperties) {