Post

Replies

Boosts

Views

Activity

UIGraphicsImageRenderer: Problem with size of the image
I have an image shot by the iPhone. This image about 2MB. I tried to render this image with UIGraphicsImageRenderer but the result is 8,2 MBMy code:let rect = CGRect(origin: .zero, size: image.size) let renderer = UIGraphicsImageRenderer(size: image.size) let result = renderer.image { (graphicsImageRendererContext) in graphicsImageRendererContext.fill(rect) image.draw(in: rect, blendMode: .normal, alpha: 1) } Anyone have an idea for it. What is the reason?
0
0
555
Mar ’20