Class TrackedTarget

java.lang.Object
org.photonvision.vision.target.TrackedTarget
All Implemented Interfaces:
Releasable

public class TrackedTarget extends Object implements Releasable
  • Field Details

    • m_mainContour

      public final Contour m_mainContour
    • m_subContours

      public List<Contour> m_subContours
  • Constructor Details

  • Method Details

    • getConfidence

      public double getConfidence()
      Returns:
      Returns the confidence of the detection ranging from 0 - 1.
    • getClassID

      public int getClassID()
      Returns:
      O-indexed class index for the detected object.
    • setFiducialId

      public void setFiducialId(int id)
    • getFiducialId

      public int getFiducialId()
    • setPoseAmbiguity

      public void setPoseAmbiguity(double ambiguity)
    • getPoseAmbiguity

      public double getPoseAmbiguity()
    • setApproximateBoundingPolygon

      public void setApproximateBoundingPolygon(org.opencv.core.MatOfPoint2f boundingPolygon)
      Set the approximate bounding polygon.
      Parameters:
      boundingPolygon - List of points to copy. Not modified.
    • getTargetOffsetPoint

      public org.opencv.core.Point getTargetOffsetPoint()
    • getRobotOffsetPoint

      public org.opencv.core.Point getRobotOffsetPoint()
    • getPitch

      public double getPitch()
    • getYaw

      public double getYaw()
    • getSkew

      public double getSkew()
    • getArea

      public double getArea()
    • getMinAreaRect

      public org.opencv.core.RotatedRect getMinAreaRect()
    • getApproximateBoundingPolygon

      public org.opencv.core.MatOfPoint2f getApproximateBoundingPolygon()
    • calculateValues

      public void calculateValues(TrackedTarget.TargetCalculationParameters params)
    • release

      public void release()
      Specified by:
      release in interface Releasable
    • setTargetCorners

      public void setTargetCorners(List<org.opencv.core.Point> targetCorners)
    • getTargetCorners

      public List<org.opencv.core.Point> getTargetCorners()
    • hasSubContours

      public boolean hasSubContours()
    • getBestCameraToTarget3d

      public Transform3d getBestCameraToTarget3d()
    • getAltCameraToTarget3d

      public Transform3d getAltCameraToTarget3d()
    • setBestCameraToTarget3d

      public void setBestCameraToTarget3d(Transform3d pose)
    • setAltCameraToTarget3d

      public void setAltCameraToTarget3d(Transform3d pose)
    • getCameraRelativeTvec

      public org.opencv.core.Mat getCameraRelativeTvec()
    • setCameraRelativeTvec

      public void setCameraRelativeTvec(org.opencv.core.Mat cameraRelativeTvec)
    • getCameraRelativeRvec

      public org.opencv.core.Mat getCameraRelativeRvec()
    • setCameraRelativeRvec

      public void setCameraRelativeRvec(org.opencv.core.Mat cameraRelativeRvec)
    • getShape

      public CVShape getShape()
    • setShape

      public void setShape(CVShape shape)
    • toHashMap

      public HashMap<String,Object> toHashMap()
    • isFiducial

      public boolean isFiducial()
    • simpleFromTrackedTargets

      public static List<PhotonTrackedTarget> simpleFromTrackedTargets(List<TrackedTarget> targets)