src/Elements/Geometry/Arc.cs
/// <summary>
/// Return the point at parameter u on the arc.
/// </summary>
/// <param name="u">A parameter between 0.0 and 1.0.</param>
/// <returns>A Vector3 representing the point along the arc.</returns>
Return the point at parameter u on the arc.
Return the point at parameter u on the arc .
public override Vector3 PointAt(double u)
        {
            if (u > 1.0 || u < 0.0)
            {
                throw new ArgumentOutOfRangeException($"The value provided for parameter u, {u}, must be between 0.0 and 1.0.");
            }
            var angle = this.StartAngle + (this.EndAngle - this.StartAngle) * u;
            var theta = DegToRad(angle);
            var x = this.Center.X + this.Radius * Math.Cos(theta);
            var y = this.Center.Y + this.Radius * Math.Sin(theta);
            return new Vector3(x, y);
        }
public override Vector3 PointAt ( double u ) { if ( u > 1.0 || u < 0.0 ) { throw new ArgumentOutOfRangeException ( $" The value provided for parameter u,  { u } , must be between 0.0 and 1.0. " ) ; } var angle = this . StartAngle + ( this . EndAngle - this . StartAngle ) * u ; var theta = DegToRad ( angle ) ; var x = this . Center . X + this . Radius * Math . Cos ( theta ) ; var y = this . Center . Y + this . Radius * Math . Sin ( theta ) ; return new Vector3 ( x , y ) ; }
Return the point at parameter u on the arc.
Return the point at parameter u on the arc .
A Vector3 representing the point along the arc.
A Vector3 representing the point along the arc .
u
double
None