我正在使用CGRect从imageview中剪切图像.矩形是根据imageview上的功能自动生成的,但我想略微放大10%但是在同一点附近.
要获得某些东西的大小,我通常会使用这样的框架:
CGRect frame = _imageView.frame;
CGImageRef imageRef = CGImageCreateWithImageInRect([image CGImage], frame);
UIImage *img = [UIImage imageWithCGImage:imageRef];
Run Code Online (Sandbox Code Playgroud)
然后用origin.x更改但是我无法获得现有矩形的框架.
任何帮助都非常赞赏扩展CGRect
归档时间: |
|
查看次数: |
1090 次 |
最近记录: |