I just check the following code for round corners on a UIImage:
- (UIImage *)makeRoundedImage:(UIImage *)image radius:(float)radius; { CALayer *imageLayer = [CALayer layer]; imageLayer.frame = CGRectMake(0, 0, image.size.width, image.size.height); imageLayer.contents = (id) image.CGImage; imageLayer.masksToBounds = YES; imageLayer.cornerRadius = radius; UIGraphicsBeginImageContext(image.size); [imageLayer renderInContext:UIGraphicsGetCurrentContext()]; UIImage *roundedImage = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext(); return roundedImage; }
I look great if you donβt look at the generated image. Corners are not smooth. How to make corners smoother / softer?
EDIT:
Processed image with rounded corners in quartz:

As you can see, the angle is not smooth.
This is the version with the UIImageView cornerRadius, which is much smoother.

Where to catch?
source share