Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface ArcCurve

Alias for EllipseCurve.

Hierarchy

Index

Constructors

constructor

  • new ArcCurve(aX: number, aY: number, aRadius: number, aStartAngle: number, aEndAngle: number, aClockwise: boolean): I3JS.ArcCurve
  • new ArcCurve(aX: number, aY: number, xRadius: number, yRadius: number, aStartAngle: number, aEndAngle: number, aClockwise: boolean, aRotation: number): I3JS.ArcCurve
  • new ArcCurve(): I3JS.ArcCurve
  • Parameters

    • aX: number
    • aY: number
    • aRadius: number
    • aStartAngle: number
    • aEndAngle: number
    • aClockwise: boolean

    Returns I3JS.ArcCurve

  • Parameters

    • aX: number

      – The X center of the ellipse. Default is 0.

    • aY: number

      – The Y center of the ellipse. Default is 0.

    • xRadius: number

      – The radius of the ellipse in the x direction. Default is 1.

    • yRadius: number

      – The radius of the ellipse in the y direction. Default is 1.

    • aStartAngle: number

      – The start angle of the curve in radians starting from the positive X axis. Default is 0.

    • aEndAngle: number

      – The end angle of the curve in radians starting from the positive X axis. Default is 2 x Math.PI.

    • aClockwise: boolean

      – Whether the ellipse is drawn clockwise. Default is false.

    • aRotation: number

      – The rotation angle of the ellipse in radians, counterclockwise from the positive X axis Default is 0.

    Returns I3JS.ArcCurve

  • This constructor creates a new Curve.

    Returns I3JS.ArcCurve

Properties

aClockwise

aClockwise: boolean

Whether the ellipse is drawn clockwise.

default

false

aEndAngle

aEndAngle: number

The end angle of the curve in radians starting from the middle right side.

default

2 * Math.PI

aRotation

aRotation: number

The rotation angle of the ellipse in radians, counterclockwise from the positive X axis Default is 0.

default

0

aStartAngle

aStartAngle: number

The start angle of the curve in radians starting from the middle right side.

default

0

aX

aX: number

The X center of the ellipse.

default

0

aY

aY: number

The Y center of the ellipse.

default

0

arcLengthDivisions

arcLengthDivisions: number

This value determines the amount of divisions when calculating the cumulative segment lengths of a curve via .getLengths. To ensure precision when using methods like .getSpacedPoints, it is recommended to increase .arcLengthDivisions if the curve is very large. Default is 200.

default

200

type

type: string
default

'ArcCurve'

xRadius

xRadius: number

The radius of the ellipse in the x direction.

default

1

yRadius

yRadius: number

The radius of the ellipse in the y direction.

default

1

Methods

clone

computeFrenetFrames

copy

fromJSON

getLength

  • getLength(): number

getLengths

  • getLengths(divisions?: number): number[]

getPoint

getPointAt

getPoints

getSpacedPoints

getTangent

  • Parameters

    • t: number

      A position on the curve. Must be in the range [ 0, 1 ].

    • Optional optionalTarget: I3JS.Vector2

      If specified, the result will be copied into this Vector, otherwise a new Vector will be created.

    Returns I3JS.Vector2

    Returns a unit vector tangent at t. If the derived curve does not implement its tangent derivation, two points a small delta apart will be used to find its gradient which seems to give a reasonable approximation.

getTangentAt

  • Parameters

    • u: number

      A position on the curve according to the arc length. Must be in the range [ 0, 1 ].

    • Optional optionalTarget: I3JS.Vector2

      If specified, the result will be copied into this Vector, otherwise a new Vector will be created.

    Returns I3JS.Vector2

    Returns tangent at a point which is equidistant to the ends of the curve from the point given in .getTangent.

getUtoTmapping

  • getUtoTmapping(u: number, distance: number): number

toJSON

  • toJSON(): object

updateArcLengths

  • updateArcLengths(): void

Generated using TypeDoc