I need to draw an arc for the given three points, I have calculated center point like below ,
float ab = (p1.Y - p2.Y) / (p1.X - p2.X); float bc = (p3.Y - p2.Y) / (p3.X - p2.X);
float xctr = (ab * bc * (p3.Y - p1.Y) + ab * (p2.X + p3.X) - bc * (p1.X + p2.X)) / (2 * (ab - bc));
float yctr = -(1 / ab) * (xctr - ((p1.X + p2.X) / 2)) + ((p1.Y + p2.Y) / 2);
float rad = (nfloat)Math.Sqrt(Math.Pow(p1.X - xctr, 2) + Math.Pow(p1.Y - yctr, 2));
Now i need to draw an arc based on these points.
Any suggestion on this would be appreciated !