Segment3D

class Segment3D

Constructors

Segment3D
Link copied to clipboard
common
fun Segment3D(start: Vector3, end: Vector3)

Linear segment constructor

Segment3D
Link copied to clipboard
common
fun Segment3D(start: Vector3, c0: Vector3, end: Vector3)

Quadratic bezier segment constructor

Segment3D
Link copied to clipboard
common
fun Segment3D(start: Vector3, c0: Vector3, c1: Vector3, end: Vector3)

Cubic bezier segment constructor

Segment3D
Link copied to clipboard
common
fun Segment3D(start: Vector3, control: Array<Vector3>, end: Vector3)

Functions

copy
Link copied to clipboard
common
fun copy(start: Vector3 = this.start, control: Array<Vector3> = this.control, end: Vector3 = this.end): Segment3D
derivative
Link copied to clipboard
common
fun derivative(t: Double): Vector3
direction
Link copied to clipboard
common
fun direction(): Vector3
fun direction(t: Double): Vector3
equals
Link copied to clipboard
common
open operator override fun equals(other: Any?): Boolean
extrema
Link copied to clipboard
common
fun extrema(): List<Double>
extremaPoints
Link copied to clipboard
common
fun extremaPoints(): List<Vector3>
hashCode
Link copied to clipboard
common
open override fun hashCode(): Int
lut
Link copied to clipboard
common
fun lut(size: Int = 100): List<Vector3>
on
Link copied to clipboard
common
fun on(point: Vector3, error: Double = 5.0): Double?
position
Link copied to clipboard
common
fun position(ut: Double): Vector3
project
Link copied to clipboard
common
fun project(point: Vector3): SegmentProjection3D
sampleAdaptive
Link copied to clipboard
common
fun sampleAdaptive(distanceTolerance: Double = 0.5): List<Vector3>
sampleAdaptiveNormals
Link copied to clipboard
common
fun sampleAdaptiveNormals(distanceTolerance: Double = 0.5): Pair<List<Vector3>, List<Vector3>>
split
Link copied to clipboard
common
fun split(t: Double): Array<Segment3D>

Split the contour

sub
Link copied to clipboard
common
fun sub(t0: Double, t1: Double): Segment3D
toString
Link copied to clipboard
common
open override fun toString(): String
transform
Link copied to clipboard
common
fun transform(transform: Matrix44): Segment3D

Properties

control
Link copied to clipboard
common
val control: Array<Vector3>

control points, zero-length iff the segment is linear

cubic
Link copied to clipboard
common
val cubic: Segment3D

Cubic version of segment

end
Link copied to clipboard
common
val end: Vector3
length
Link copied to clipboard
common
val length: Double
linear
Link copied to clipboard
common
val linear: Boolean
reverse
Link copied to clipboard
common
val reverse: Segment3D
start
Link copied to clipboard
common
val start: Vector3