is there anyway we can do rotation of image in a pendulum effect in iphone using UIView Animation or CoreAnimation
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Use
CGAffineTransformRotateto rotate your UIImageView e.g.Also, you’ll need to set up the anchor point on your image, prior to rotating it, so that you can make it
swingfrom the correct position. e.g.Obviously, you’ll need to set up a timer to adjust move the image and control the angle. You could do something like the following in a timer. (untested)