How can I add 16 dot in circular path when the user select a location x,y in my View and the dots should be in a equal distances,
so when the user hit a location in the view, I will complete the circle with 16 dot, see attachment.
the image is the use from this code:
CGPoint CenterPoint = CGPointMake(self.frame.size.width / 2, self.frame.size.height / 2);
CGPoint Point;
float Angel = 360/16;
for (int i = 0 ; i < 16;i++)
{
float distance = [self distanceFrom:newPoint to:centerPoint];
Point.x = CenterPoint.x + distance * cos(Angel);
Point.y = CenterPoint.y + distance * sin(Angel);
CGContextMoveToPoint(cacheContext, Point.x, Point.y);
CGContextAddLineToPoint(cacheContext, Point.x, Point.y);
CGContextStrokePath(cacheContext);
Angel+= 10;
}