core / com.acmerobotics.roadrunner.path / Path

Path

class Path

Path composed of a parametric curve and a heading interpolator.

Parameters

parametricCurve - parametric curve

interpolator - heading interpolator

reversed - whether or not to travel along the path in reverse

Types

ProjectionResult

class ProjectionResult

Constructors

<init>

Path(parametricCurve: ParametricCurve, interpolator: HeadingInterpolator = TangentInterpolator(), reversed: Boolean = false)Path(parametricCurves: List<ParametricCurve>, interpolators: List<HeadingInterpolator> = parametricCurves.map { TangentInterpolator() }, reversed: List<Boolean> = parametricCurves.map { false })

Path composed of a parametric curve and a heading interpolator.

Properties

interpolators

val interpolators: List<HeadingInterpolator>

parametricCurves

val parametricCurves: List<ParametricCurve>

reversed

val reversed: List<Boolean>

whether or not to travel along the path in reverse

Functions

deriv

fun deriv(displacement: Double): Pose2d

Returns the pose derivative displacement units along the path.

end

fun end(): Pose2d

Returns the end pose.

endDeriv

fun endDeriv(): Pose2d

Returns the end pose derivative.

endSecondDeriv

fun endSecondDeriv(): Pose2d

Returns the end pose second derivative.

get

operator fun get(displacement: Double): Pose2d

Returns the pose displacement units along the path.

length

fun length(): Double

Returns the length of the path.

project

fun project(point: Vector2d, projectGuess: Double = length() / 2.0): ProjectionResult

Project point onto the current path.

secondDeriv

fun secondDeriv(displacement: Double): Pose2d

Returns the pose second derivative displacement units along the path.

start

fun start(): Pose2d

Returns the start pose.

startDeriv

fun startDeriv(): Pose2d

Returns the start pose derivative.

startSecondDeriv

fun startSecondDeriv(): Pose2d

Returns the start pose second derivative.