Package frc.robot.util
Class BiAlliancePose3d
java.lang.Object
frc.robot.util.BiAlliancePose3d
A Pose3d that contains versions for the Blue and Red alliances.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumChanges the Y-Axis behavior when flipping the alliance. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic BiAlliancePose3dfromBluePose(Pose3d bluePose, BiAlliancePose3d.InvertY invertY) Creates a BiAlliancePose3d from a pose on the blue alliance.static BiAlliancePose3dfromRedPose(Pose3d redPose, BiAlliancePose3d.InvertY invertY) Creates a BiAlliancePose2d from a pose on the red alliance.Gets this pose on the blue alliance.Gets this pose for the current alliance.Gets this pose on the red alliance.
-
Field Details
-
bluePose
The pose on the blue alliance. -
redPose
The pose on the red alliance.
-
-
Method Details
-
fromBluePose
Creates a BiAlliancePose3d from a pose on the blue alliance.- Parameters:
bluePose- The pose on the blue alliance.invertY- Should the Y value be inverted?
-
fromRedPose
Creates a BiAlliancePose2d from a pose on the red alliance.- Parameters:
redPose- The pose on the red alliance.invertY- Should the Y value be inverted?
-
getBluePose
Gets this pose on the blue alliance.- Returns:
- The pose on the blue alliance.
- See Also:
-
getRedPose
Gets this pose on the red alliance.- Returns:
- The pose on the red alliance.
- See Also:
-
getPoseByAlliance
Gets this pose for the current alliance.- Returns:
- The pose for the current alliance.
-