private static async Task <MapPoint> CreatePointAlongArc(MapPoint startPt, MapPoint endPt, MapPoint centerPt, double angle, double radius, SpatialReference spatRef, bool arcIsMinor, bool arcIsCounterClockwise)
        {
            System.Windows.Media.Media3D.Vector3D start = new System.Windows.Media.Media3D.Vector3D(startPt.X - centerPt.X, startPt.Y - centerPt.Y, startPt.Z - centerPt.Z);
            System.Windows.Media.Media3D.Vector3D end   = new System.Windows.Media.Media3D.Vector3D(endPt.X - centerPt.X, endPt.Y - centerPt.Y, endPt.Z - centerPt.Z);

            System.Windows.Media.Media3D.Vector3D normalOfPlane = new System.Windows.Media.Media3D.Vector3D();
            normalOfPlane = System.Windows.Media.Media3D.Vector3D.CrossProduct(start, end);

            //Two ortho vectors: orthoVec and start
            System.Windows.Media.Media3D.Vector3D orthoVec = new System.Windows.Media.Media3D.Vector3D();
            orthoVec = System.Windows.Media.Media3D.Vector3D.CrossProduct(normalOfPlane, start);

            //If this is not done then half of the keyframes for S-shaped curve are not on the curve
            if (arcIsMinor && !arcIsCounterClockwise)
            {
                orthoVec.Negate();
            }

            //Normalize
            start.Normalize();
            orthoVec.Normalize();

            System.Windows.Media.Media3D.Vector3D ptAlong = new System.Windows.Media.Media3D.Vector3D();
            ptAlong = radius * Math.Cos(angle) * start + radius * Math.Sin(angle) * orthoVec;

            MapPoint intermediateKeyframePoint = await QueuedTask.Run(() => MapPointBuilder.CreateMapPoint(ptAlong.X + centerPt.X, ptAlong.Y + centerPt.Y, ptAlong.Z + centerPt.Z, spatRef));

            return(intermediateKeyframePoint);
        }