Create a background image and images for each of your hands (seconds, minutes, hours - whatever you want). Each image should be as large as a clock, but not scaled. Put your hands on the 12 mark. Do the rest alpha in the images with your hands.
Now, put all the images in the same place in your image / magnifier view. Your watch should read 12 hours.
In your code, create a method that will be called every second by a timer. This method will rotate the views so that the arms are turned into the correct position. You can use the conversion property of NSView or UIView .
Note. Apple explains this in detail: "Translate, scale, and rotate views . " Example:
// M_PI/4.0 is one quarter of a half circle, or 45 degrees. CGAffineTransform xform = CGAffineTransformMakeRotation(M_PI/4.0); hourHandsImageView.transform = xform;
Just by changing the images, you can change the look.
source share