像标准功能一样旋转图像 ios objective c

Rotating image like in standard feature ios objective c

如何像在标准图库功能中那样旋转图像?标准画廊有滚轮,用户可以用一根手指点击滚轮,然后从左向右滑动并将图像旋转 45 度。 这是我的意思的截图:

尝试使用此代码进行轮播。

CGAffineTransform newTransform = CGAffineTransformMakeRotation((CGFloat)(angel));

self.imageView.transform = newTransform;

尝试使用此代码进行轮换。

CGFloat degrees = 45.0f; //the value in degrees
CGFloat radians = degrees * M_PI/180;
imageView.transform = CGAffineTransformMakeRotation(radians);

我觉得你需要单指旋转。

这是您可以使用的库:

https://github.com/zedoul/ZDStickerView