public interface FrameTuple2DBasics extends FixedFrameTuple2DBasics
FrameTuple2DBasics
is the base implementation for FramePoint2D
and
FrameVector2D
.
In addition to representing a Tuple2DBasics
, a ReferenceFrame
is associated to a
FrameTuple2DBasics
. This allows, for instance, to enforce, at runtime, that operations on
tuples occur in the same coordinate system.
This interface allows for changing the reference frame in which this tuple is expressed.
Because a FrameTuple2DBasics
extends Tuple2DBasics
, it is compatible with methods
only requiring Tuple2DBasics
. However, these methods do NOT assert that the operation
occur in the proper coordinate system. Use this feature carefully and always prefer using methods
requiring FrameTuple2DBasics
.
Modifier and Type | Method and Description |
---|---|
default void |
setIncludingFrame(FrameTuple2DReadOnly other)
Sets this frame tuple to
other . |
default void |
setIncludingFrame(FrameTuple3DReadOnly frameTuple3DReadOnly)
Sets this frame tuple from the reference frame, x and y components of the given
frameTuple3DReadOnly . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
org.ejml.data.DenseMatrix64F matrix)
Sets this tuple's components
x , y in order from the given column vector starting
to read from its first row index and sets this tuple frame to referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
double[] tupleArray)
Sets this tuple's components
x , y in order from the given array
tupleArray and sets this tuple frame to referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
double x,
double y)
Sets this frame tuple's components to
x and y and sets its reference frame to
referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
int startRow,
org.ejml.data.DenseMatrix64F matrix)
Sets this tuple's components
x , y in order from the given column vector starting
to read from startRow and sets this tuple frame to referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
int startIndex,
double[] tupleArray)
Sets this tuple's components
x , y in order from the given array
tupleArray and sets this tuple frame to referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
int startRow,
int column,
org.ejml.data.DenseMatrix64F matrix)
Sets this tuple's components
x , y in order from the given matrix starting to read
from startRow at the column index column and sets this tuple frame to
referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
us.ihmc.euclid.tuple2D.interfaces.Tuple2DReadOnly tuple2DReadOnly)
Sets this frame tuple to
tuple2DReadOnly and sets its current frame to
referenceFrame . |
default void |
setIncludingFrame(ReferenceFrame referenceFrame,
us.ihmc.euclid.tuple3D.interfaces.Tuple3DReadOnly tuple3DReadOnly)
Sets this frame tuple to
tuple3DReadOnly and sets its current frame to
referenceFrame . |
void |
setReferenceFrame(ReferenceFrame referenceFrame)
Sets the reference frame of this tuple without updating or modifying its x and y components.
|
default void |
setToNaN(ReferenceFrame referenceFrame)
Sets all the components of this tuple to
Double.NaN and sets the current reference frame
to referenceFrame . |
default void |
setToZero(ReferenceFrame referenceFrame)
Sets all the components of this frame tuple to zero and sets the current reference frame to
referenceFrame . |
add, add, add, add, interpolate, interpolate, interpolate, interpolate, scaleAdd, scaleAdd, scaleAdd, scaleAdd, scaleSub, scaleSub, scaleSub, scaleSub, set, set, set, set, setAndAbsolute, setAndClipToMax, setAndClipToMin, setAndClipToMinMax, setAndNegate, setAndScale, setMatchingFrame, sub, sub, sub, sub
epsilonEquals, equals
checkReferenceFrameMatch, checkReferenceFrameMatch, getReferenceFrame
absolute, add, add, add, addX, addY, applyInverseTransform, applyInverseTransform, applyTransform, applyTransform, clipToMax, clipToMin, clipToMinMax, containsNaN, interpolate, interpolate, negate, scale, scale, scaleAdd, scaleAdd, scaleSub, scaleSub, set, set, set, set, set, set, set, set, set, set, setAndAbsolute, setAndClipToMax, setAndClipToMin, setAndClipToMinMax, setAndNegate, setAndScale, setElement, setToNaN, setToZero, setX, setY, sub, sub, sub, subX, subY
void setReferenceFrame(ReferenceFrame referenceFrame)
referenceFrame
- the new reference frame for this frame tuple.default void setToZero(ReferenceFrame referenceFrame)
referenceFrame
.referenceFrame
- the new reference frame to be associated with this tuple.default void setToNaN(ReferenceFrame referenceFrame)
Double.NaN
and sets the current reference frame
to referenceFrame
.referenceFrame
- the new reference frame to be associated with this tuple.default void setIncludingFrame(ReferenceFrame referenceFrame, double x, double y)
x
and y
and sets its reference frame to
referenceFrame
.referenceFrame
- the new reference frame for this frame tuple.x
- the new value for the x-component of this tuple.y
- the new value for the y-component of this tuple.default void setIncludingFrame(ReferenceFrame referenceFrame, us.ihmc.euclid.tuple2D.interfaces.Tuple2DReadOnly tuple2DReadOnly)
tuple2DReadOnly
and sets its current frame to
referenceFrame
.referenceFrame
- the new reference frame for this frame tuple.tuple2DReadOnly
- the tuple to copy the values from. Not modified.default void setIncludingFrame(ReferenceFrame referenceFrame, us.ihmc.euclid.tuple3D.interfaces.Tuple3DReadOnly tuple3DReadOnly)
tuple3DReadOnly
and sets its current frame to
referenceFrame
.referenceFrame
- the new reference frame for this frame tuple.tuple3DReadOnly
- the tuple to copy the values from. Not modified.default void setIncludingFrame(ReferenceFrame referenceFrame, double[] tupleArray)
x
, y
in order from the given array
tupleArray
and sets this tuple frame to referenceFrame
.referenceFrame
- the new reference frame for this tuple.tupleArray
- the array containing the new values for this tuple's components. Not modified.default void setIncludingFrame(ReferenceFrame referenceFrame, int startIndex, double[] tupleArray)
x
, y
in order from the given array
tupleArray
and sets this tuple frame to referenceFrame
.referenceFrame
- the new reference frame for this tuple.startIndex
- the first index to start reading from in the array.tupleArray
- the array containing the new values for this tuple's components. Not modified.default void setIncludingFrame(ReferenceFrame referenceFrame, org.ejml.data.DenseMatrix64F matrix)
x
, y
in order from the given column vector starting
to read from its first row index and sets this tuple frame to referenceFrame
.referenceFrame
- the new reference frame for this tuple.matrix
- the column vector containing the new values for this tuple's components. Not
modified.default void setIncludingFrame(ReferenceFrame referenceFrame, int startRow, org.ejml.data.DenseMatrix64F matrix)
x
, y
in order from the given column vector starting
to read from startRow
and sets this tuple frame to referenceFrame
.referenceFrame
- the new reference frame for this tuple.startRow
- the first row index to start reading in the dense-matrix.matrix
- the column vector containing the new values for this tuple's components. Not
modified.default void setIncludingFrame(ReferenceFrame referenceFrame, int startRow, int column, org.ejml.data.DenseMatrix64F matrix)
x
, y
in order from the given matrix starting to read
from startRow
at the column index column
and sets this tuple frame to
referenceFrame
.referenceFrame
- the new reference frame for this tuple.startRow
- the first row index to start reading in the dense-matrix.column
- the column index to read in the dense-matrix.matrix
- the column vector containing the new values for this tuple's components. Not
modified.default void setIncludingFrame(FrameTuple3DReadOnly frameTuple3DReadOnly)
frameTuple3DReadOnly
.frameTuple3DReadOnly
- the tuple to copy the values and reference frame from. Not modified.default void setIncludingFrame(FrameTuple2DReadOnly other)
other
.other
- the other frame tuple to copy the values and reference frame from. Not modified.