Segment3D

@Serializable
class Segment3D(val start: Vector3, val control: List<Vector3>, val end: Vector3) : BezierSegment<Vector3> (source)

Constructors

Link copied to clipboard
constructor(start: Vector3, control: List<Vector3>, end: Vector3)

Functions

Link copied to clipboard
open fun adaptivePositions(distanceTolerance: Double = 0.5): List<Vector3>

Recursively subdivides Segment2D to approximate Bézier curve.

Link copied to clipboard
open fun adaptivePositionsWithT(distanceTolerance: Double = 0.5): List<Pair<Vector3, Double>>
Link copied to clipboard
fun copy(start: Vector3 = this.start, control: List<Vector3> = this.control, end: Vector3 = this.end): Segment3D
Link copied to clipboard
open override fun derivative(t: Double): Vector3
Link copied to clipboard
open fun direction(): Vector3

Returns the direction T of between the Segment2D anchor points.

open fun direction(t: Double): Vector3
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open fun equidistantPositions(pointCount: Int, distanceTolerance: Double = 0.5): List<Vector3>

Samples specified amount of points on the Segment2D.

Link copied to clipboard
open fun equidistantPositionsWithT(pointCount: Int, distanceTolerance: Double = 0.5): List<Pair<Vector3, Double>>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
fun lut(size: Int = 100): List<Vector3>
Link copied to clipboard
fun on(point: Vector3, error: Double = 5.0): Double?
Link copied to clipboard
open fun pointAtLength(length: Double, distanceTolerance: Double): Vector3

Calculates the point at a given distance along this Segment2D.

Link copied to clipboard
open override fun position(ut: Double): Vector3

Returns a point on the segment.

Link copied to clipboard
Link copied to clipboard
open override fun split(t: Double): Array<Segment3D>

Split the contour

Link copied to clipboard
open fun sub(t0: Double, t1: Double): BezierSegment<Vector3>

Samples a new Segment2D from the current Segment2D starting at t0 and ending at t1.

Link copied to clipboard
open override fun tForLength(length: Double): Double

Estimate t value for a given length

Link copied to clipboard
open override fun toString(): String
Link copied to clipboard
fun transform(transform: Matrix44): Segment3D

Properties

Link copied to clipboard
open override val control: List<Vector3>
Link copied to clipboard
open override val cubic: Segment3D

Cubic version of segment

Link copied to clipboard
open override val end: Vector3
Link copied to clipboard
open override val length: Double
Link copied to clipboard
@Transient
open val linear: Boolean

Indicates whether the Segment2D is linear.

Link copied to clipboard
open override val reverse: Segment3D
Link copied to clipboard
open override val start: Vector3
Link copied to clipboard
@Transient
open val type: SegmentType

Returns the type of the segment.