Hank Brekke
Hank Brekke

Reputation: 2024

Rotate and Scale UIImageView with animation

How can I get a UIImageView to rotate itself 90° counter-clockwise and have the same UIImageView scale to fill the entire iPhone screen with animation at speeds of one-second?

Upvotes: 1

Views: 1329

Answers (2)

Hank Brekke
Hank Brekke

Reputation: 2024

I'm using .tranform and M_PI for rotation, and changing the frame size

Upvotes: 0

Jason Foreman
Jason Foreman

Reputation: 2146

Create a CGAffineTransform that embodies your rotation and scale, then set it as the transform property of your view inside of an animation block which has a 1 second duration.

Upvotes: 3

Related Questions