mirror of
https://github.com/zhigang1992/PINRemoteImage.git
synced 2026-04-24 04:15:32 +08:00
Merge pull request #242 from pinterest/AHBlendMode
Use kCGBlendModeCopy when Decoding Images
This commit is contained in:
@@ -150,6 +150,7 @@ NSData * __nullable PINImagePNGRepresentation(PINImage * __nonnull image) {
|
||||
|
||||
PINImage *decodedImage = nil;
|
||||
if (ctx) {
|
||||
CGContextSetBlendMode(ctx, kCGBlendModeCopy);
|
||||
CGContextDrawImage(ctx, CGRectMake(0, 0, imageSize.width, imageSize.height), imageRef);
|
||||
|
||||
CGImageRef newImage = CGBitmapContextCreateImage(ctx);
|
||||
|
||||
Reference in New Issue
Block a user