ICurve

Description

interface Tinman.Terrain.Util.ICurve

Derived from

ISerializable
IEquatable<ICurve>
IConfigurable

Extended by

Curve abstract

Base interface for classes that represent a curve that interpolates through a sequence of control points.

Public / Methods

Add


public method Add → (4)

in : float64

X-coordinate of the control point.

opt : float64 = 0

Y-coordinate of the control point.

opt : float64 = 0

Z-coordinate of the control point.

opt : float64 = 0

W-coordinate of the control point.

returns → ICurve

this

Adds a control point to this curve.

Clear


public method Clear → ()

returns → ICurve

this

Removes all control points from this curve.

Compute1D


public method Compute1D → (1)

index in : float64

The control point index.

returns → float64

The computed point or Maths.NanD if the curve has no control points.

Computes a 1D point along this curve.

Compute2D


public method Compute2D → (1)

index in : float64

The control point index.

returns → Vec2D

The computed point or Vec2D.Undefined if the curve has no control points.

Computes a 2D point along this curve.

Compute3D


public method Compute3D → (1)

index in : float64

The control point index.

returns → Vec3D

The computed point or Vec3D.Undefined if the curve has no control points.

Computes a 3D point along this curve.

Compute4D


public method Compute4D → (1)

index in : float64

The control point index.

returns → Vec4D

The computed point or Vec4D.Undefined if the curve has no control points.

Computes a 4D point along this curve.

GetAt


public method GetAt → (1)

index in : int32

[0..ICurve.Count-1]
The control point index.

returns → Vec4D

The control point.

Returns a control point.

Public / Attributes

Continuity


public attribute Continuity → (get)

value : Continuity

The continuity of this curve.

The continuity type of this curve.

Count


public attribute Count → (get)

value : int32

[>=0]
The number of control points.

The number of control points.

ValidRange


public attribute ValidRange → (get)

value : RangeI

The valid control point index range.

Returns the range of valid control point indices.

Control points within this range can be used to compute points on the curve without the need to duplicate any control points.

Extensions

Add

3 overloads


public static method Add1 → (1)

in : Vec2D

The control point.

returns → ICurve

this

Adds a control point to this curve.


public static method Add2 → (1)

in : Vec3D

The control point.

returns → ICurve

this

Adds a control point to this curve.


public static method Add3 → (1)

in : Vec4D

The control point.

returns → ICurve

this

Adds a control point to this curve.