Show / Hide Table of Contents

    Class Ellipse

    An ellipse. Parameterization of the curve is 0 -> 2PI.

    Inheritance
    System.Object
    Curve
    Ellipse
    Implements
    ICurve
    ITransformable<Curve>
    IConic
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Elements.Geometry
    Assembly: Hypar.Elements.dll
    Syntax
    public class Ellipse : Curve, ICurve, ITransformable<Curve>, IConic

    Constructors

    Ellipse(Transform, Double, Double)

    Create an ellipse.

    Declaration
    [JsonConstructor]
    public Ellipse(Transform transform, double majorAxis = 2, double minorAxis = 1)
    Parameters
    Type Name Description
    Transform transform

    The coordinate system of the plane containing the ellipse.

    System.Double majorAxis

    The dimension of the major axis (X) of the ellipse.

    System.Double minorAxis

    The dimension of the minor axis (Y) of the ellipse.

    Ellipse(Vector3, Double, Double)

    Create an ellipse.

    Declaration
    public Ellipse(Vector3 center, double majorAxis = 2, double minorAxis = 1)
    Parameters
    Type Name Description
    Vector3 center

    The center of the ellipse.

    System.Double majorAxis

    The dimension of the major axis (X) of the ellipse.

    System.Double minorAxis

    The dimension of the minor axis (Y) of the ellipse.

    Ellipse(Double, Double)

    Create an ellipse.

    Declaration
    public Ellipse(double majorAxis = 1, double minorAxis = 2)
    Parameters
    Type Name Description
    System.Double majorAxis

    The dimension of the major axis (X) of the ellipse.

    System.Double minorAxis

    The dimension of the minor axis (Y) o the ellipse.

    Properties

    Center

    The center of the ellipse.

    Declaration
    [JsonIgnore]
    public Vector3 Center { get; }
    Property Value
    Type Description
    Vector3

    MajorAxis

    The dimension of the major axis (X) of the ellipse.

    Declaration
    public double MajorAxis { get; set; }
    Property Value
    Type Description
    System.Double

    MinorAxis

    The dimension of the minor axis (Y) of the ellipse.

    Declaration
    public double MinorAxis { get; set; }
    Property Value
    Type Description
    System.Double

    Transform

    The coordinate system of the plane containing the ellipse.

    Declaration
    public Transform Transform { get; protected set; }
    Property Value
    Type Description
    Transform

    Methods

    ParameterAtDistanceFromParameter(Double, Double)

    Get the parameter at a distance from the start parameter along the curve.

    Declaration
    public override double ParameterAtDistanceFromParameter(double distance, double start)
    Parameters
    Type Name Description
    System.Double distance

    The distance from the start parameter.

    System.Double start

    The parameter from which to measure the distance.

    Returns
    Type Description
    System.Double
    Overrides
    Curve.ParameterAtDistanceFromParameter(Double, Double)

    PointAt(Double)

    Get a point along the ellipse at parameter u.

    Declaration
    public override Vector3 PointAt(double u)
    Parameters
    Type Name Description
    System.Double u
    Returns
    Type Description
    Vector3

    A point on the ellipse at parameter u.

    Overrides
    Curve.PointAt(Double)

    TransformAt(Double)

    Get a transform along the ellipse at parameter u.

    Declaration
    public override Transform TransformAt(double u)
    Parameters
    Type Name Description
    System.Double u
    Returns
    Type Description
    Transform

    A transform on the ellipse at parameter u.

    Overrides
    Curve.TransformAt(Double)

    Transformed(Transform)

    Create a transformed copy of this curve. Use of non-affine transforms (i.e. scale) will result in unpredictable results for curve methods such as Length().

    Declaration
    public override Curve Transformed(Transform transform)
    Parameters
    Type Name Description
    Transform transform

    The transform to apply.

    Returns
    Type Description
    Curve
    Overrides
    Curve.Transformed(Transform)

    Implements

    ICurve
    ITransformable<T>
    IConic