أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.
I very this two concepts please help me.
You can use a CGImageMask;
UIView*rotatedViewBox =[[UIView alloc] initWithFrame:CGRectMake(0.0f,0.0f, inImage.size.width, inImage.size.height)]; rotatedViewBox.transform =CGAffineTransformMakeRotation(inAngle);CGSize rotatedSize = rotatedViewBox.frame.size;UIGraphicsBeginImageContext(rotatedSize);CGContextRef bitmap =UIGraphicsGetCurrentContext();CGContextTranslateCTM(bitmap, rotatedSize.width /2.0f, rotatedSize.height /2.0f);CGContextRotateCTM(bitmap, inAngle);CGContextScaleCTM(bitmap,1.0f,-1.0f);CGContextDrawImage(bitmap,CGRectMake(-inImage.size.width /2.0f,-inImage.size.height /2.0f, inImage.size.width, inImage.size.height), inImage.CGImage);UIImage*resultImage =UIGraphicsGetImageFromCurrentImageContext();UIGraphicsEndImageContext();