Class Limelight.FiducialTarget
java.lang.Object
com.limelightvision.Limelight.LimelightTarget
com.limelightvision.Limelight.FiducialTarget
- Enclosing class:
Limelight
An AprilTag/fiducial target.
-
Field Summary
FieldsModifier and TypeFieldDescriptiondoublePose ambiguity.double[]Camera pose in target space [x, y, z, roll, pitch, yaw] (meters, degrees).Fiducial family (e.g.intFiducial/AprilTag ID.booleanTrue if this tag contributed to pose estimation.double[]Robot pose in field space (MegaTag1, this tag only).double[]Robot pose in field space (MegaTag2, this tag only).double[]Robot pose in target space.double[]Target skew values.double[]Target pose in camera space.double[]Target pose in robot space.Fields inherited from class Limelight.LimelightTarget
corners, targetAreaPercent, txDegrees, txDegreesNoCrosshair, txPixels, tyDegrees, tyDegreesNoCrosshair, tyPixels -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.wpilib.math.geometry.Pose3dReturns camera pose in target space as a Pose3d.doubleReturns 3D distance from the camera to this tag in meters.doubleReturns 3D distance from the robot center to this tag in meters.org.wpilib.math.geometry.Pose3dReturns megaTag1 robot pose in field space from this tag only, as a Pose3d.org.wpilib.math.geometry.Pose3dReturns megaTag2 robot pose in field space from this tag only, as a Pose3d.org.wpilib.math.geometry.Pose3dReturns robot pose in target space as a Pose3d.org.wpilib.math.geometry.Pose3dReturns target pose in camera space as a Pose3d.org.wpilib.math.geometry.Pose3dReturns target pose in robot space as a Pose3d.
-
Field Details
-
fiducialId
public int fiducialIdFiducial/AprilTag ID. -
family
Fiducial family (e.g. "36h11") -
skew
public double[] skewTarget skew values. -
ambiguity
public double ambiguityPose ambiguity. Lower is better. Values above 0.7 are usually not reliable -
fielded
public boolean fieldedTrue if this tag contributed to pose estimation. The tag matched the field map and the ID filters did not exclude it. -
cameraPoseTargetSpace
public double[] cameraPoseTargetSpaceCamera pose in target space [x, y, z, roll, pitch, yaw] (meters, degrees). -
targetPoseCameraSpace
public double[] targetPoseCameraSpaceTarget pose in camera space. -
targetPoseRobotSpace
public double[] targetPoseRobotSpaceTarget pose in robot space. -
robotPoseTargetSpace
public double[] robotPoseTargetSpaceRobot pose in target space. -
robotPoseFieldSpace
public double[] robotPoseFieldSpaceRobot pose in field space (MegaTag1, this tag only). -
robotPoseFieldSpaceMT2
public double[] robotPoseFieldSpaceMT2Robot pose in field space (MegaTag2, this tag only).
-
-
Constructor Details
-
FiducialTarget
public FiducialTarget()
-
-
Method Details
-
getDistanceToCamera
public double getDistanceToCamera()Returns 3D distance from the camera to this tag in meters.- Returns:
- 3D distance from the camera to this tag in meters
-
getDistanceToRobot
public double getDistanceToRobot()Returns 3D distance from the robot center to this tag in meters.- Returns:
- 3D distance from the robot center to this tag in meters
-
getCameraPose_TargetSpace
public org.wpilib.math.geometry.Pose3d getCameraPose_TargetSpace()Returns camera pose in target space as a Pose3d.- Returns:
- Camera pose in target space as a Pose3d
-
getTargetPose_CameraSpace
public org.wpilib.math.geometry.Pose3d getTargetPose_CameraSpace()Returns target pose in camera space as a Pose3d.- Returns:
- Target pose in camera space as a Pose3d
-
getTargetPose_RobotSpace
public org.wpilib.math.geometry.Pose3d getTargetPose_RobotSpace()Returns target pose in robot space as a Pose3d.- Returns:
- Target pose in robot space as a Pose3d
-
getRobotPose_TargetSpace
public org.wpilib.math.geometry.Pose3d getRobotPose_TargetSpace()Returns robot pose in target space as a Pose3d.- Returns:
- Robot pose in target space as a Pose3d
-
getRobotPose_FieldSpace
public org.wpilib.math.geometry.Pose3d getRobotPose_FieldSpace()Returns megaTag1 robot pose in field space from this tag only, as a Pose3d.- Returns:
- MegaTag1 robot pose in field space from this tag only, as a Pose3d
-
getRobotPose_FieldSpace_MT2
public org.wpilib.math.geometry.Pose3d getRobotPose_FieldSpace_MT2()Returns megaTag2 robot pose in field space from this tag only, as a Pose3d.- Returns:
- MegaTag2 robot pose in field space from this tag only, as a Pose3d
-