How to move uiview along the trajectory of a circle?

Is there any way to animate uiview moving with a cicle path? enter image description here

+5
source share
2 answers

You will need to create a circular path and animate your view along the way. You can use UIBezierPath to create a circular path. Here is an example that does exactly what you want.

+4
source

There are several options. Probably the easiest is to place your view on the parent view, and then animate the rotation of the parent view around its Z axis.

, , , . . , .

, , CGPath , , .

+4

All Articles