Hjalmar Hjalmar - 1 year ago 138
iOS Question

Get the current angle/rotation/radian for a UIview?

How do you get the current angle/rotation/radian a UIview has?

Answer Source

You can do it this way...

CGFloat radians = atan2f(yourView.transform.b, yourView.transform.a); 
CGFloat degrees = radians * (180 / M_PI);
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download