I need to create a rotation animation for a uiimageview. The best analogy I can think of is a picture hanging on a wall. The nail that holds up the picture is placed at the top of the picture.
If I pushed the picture I want to model the slight swinging motion of the picture back and forth until it eventually reverts back its its starting position.
I know I'll first have to start by changing the view's anchor point but I'm unsure how to approach the rest of the problem. I could use CABasicAnimation but I'm guessing that would be ridiculously complex/overkill to get a relatively simple animation.
Any suggestions?
[EDIT]
This answer actually worked for me nicely using blocks :)