// Construct a circular arc from (2, 1) to (1, 2)
// with center point at (1, 1) and orientation counterclockwise.
// Use a builder convenience method or use a builder constructor.
MapPoint toPt = MapPointBuilder.CreateMapPoint(1, 2);
MapPoint fromPt = MapPointBuilder.CreateMapPoint(2, 1);
Coordinate2D centerPtCoord = new Coordinate2D(1, 1);
// Builder convenience methods don't need to run on the MCT.
EllipticArcSegment circularArc = EllipticArcBuilder.CreateEllipticArcSegment(fromPt, toPt, centerPtCoord, esriArcOrientation.esriArcCounterClockwise);
// Builder constructors need to run on the MCT.
ArcGIS.Desktop.Framework.Threading.Tasks.QueuedTask.Run(() =>
{
using (EllipticArcBuilder cab = new EllipticArcBuilder(fromPt, toPt, centerPtCoord, esriArcOrientation.esriArcCounterClockwise))
{
// do something with the builder
EllipticArcSegment otherCircularArc = cab.ToSegment();
}
});