iOS - 如何从中心旋转imageView 360度

use*_*937 -3 animation uikit uiimageview ios

我想在我的iOS应用程序中旋转我的imageView 360度

(当我的标签文字是"你好")

请帮我

if ([myLabel.text isEqualToString:@"hello"] == YES)
{
    //here i want the imageView to rotate

}
Run Code Online (Sandbox Code Playgroud)

use*_*323 5

看来你想让它变得生动.否则,图像视图没有变化.

#define DEGREES_IN_RADIANS(x) (M_PI * x / 180.0);

[UIView animateWithDuration:duration animations:^{

imageView.transform = CGAffineTransformMakeRotation(DEGREES_IN_RADIANS(360));

} completion:nil];
Run Code Online (Sandbox Code Playgroud)