You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched Google , stackoverflow and React-Native repo but no lucky, so asking help here.
I using the following snippets for load image , both local image and remote image are working very well except gif image.
When downloading Gif image, the UIImage* image only display the first frame and can not convert to NSData.
The problem here is i want a NSData object from UIImage, but seems like the UIImage is not an animated image when download block has done.
// load image
[_bridge.imageLoader loadImageWithURLRequest:d.source.request
size:d.source.size
scale:d.source.scale
clipped:NOresizeMode:RCTResizeModeStretch
progressBlock:^(int64_t progress, int64_t total) {
NSLog(@"%lld%lld", progress,total);
}
partialLoadBlock:nilcompletionBlock:^(NSError* error, UIImage* image) {
if (image) {
dispatch_async(dispatch_get_main_queue(), ^{
// if the image is an gif file, the UIImage only display the first frame.
});
}
}];
This issue looks like a question that would be best asked on StackOverflow.
StackOverflow is amazing for Q&A: it has a reputation system, voting, the ability to mark a question as answered. Because of the reputation system it is likely the community will see and answer your question there. This also helps us use the GitHub bug tracker for bugs only.
Will close this as this is really a question that should be asked on StackOverflow.
Is this a bug report?
No.
Have you read the Contributing Guidelines?
Yes.
Environment
react-native -v
: react-native-cli: 2.0.1 react-native: 0.47.1node -v
: v8.1.4npm -v
: 5.3.0yarn --version
: 0.27.5I have searched Google , stackoverflow and React-Native repo but no lucky, so asking help here.
I using the following snippets for load image , both local image and remote image are working very well except
gif
image.When downloading Gif image, the
UIImage* image
only display the first frame and can not convert to NSData.The problem here is i want a NSData object from UIImage, but seems like the UIImage is not an animated image when download block has done.
repo: https://github.com/merryjs/photo-viewer/blob/refactor-image-loader/ios/MerryPhotoView.m#L222
The text was updated successfully, but these errors were encountered: