Wraps a limelight target in a usable object.
More...
#include <shooter_subsystem.h>
|
static constexpr units::millisecond_t | m_miscLatency {11_ms} |
| Any extra latency to account for. More...
|
|
Wraps a limelight target in a usable object.
- Copyright
- Copyright (c) Argos FRC Team 1756. Open Source Software; you can modify and/or share it under the terms of the license file in the root directory of this project.
◆ LimelightTarget()
LimelightTarget::LimelightTarget |
( |
| ) |
|
|
default |
◆ adjustPerspective()
void LimelightTarget::adjustPerspective |
( |
units::degree_t & |
currentPitch, |
|
|
const units::degree_t & |
currentYaw |
|
) |
| |
Adjusts pitch based on the current yaw to correct the camera perspective. Perspective distortion polynomial determined empirically.
- Parameters
-
[in,out] | currentPitch | Pitch reported by camera; updated according to perspective distortion |
[in] | currentYaw | Yaw reported by camera |
◆ GetTarget()
Get the values of the camera's current target.
- Returns
- tValues
◆ HasTarget()
bool LimelightTarget::HasTarget |
( |
| ) |
|
Does the camera see a target?
- Returns
- true - The camera does see a target
-
false - The camera does not see a target
◆ m_bboxHor
double LimelightTarget::m_bboxHor |
|
private |
Longest edge of bounding box (horizontal in our case) in px.
◆ m_bboxVer
double LimelightTarget::m_bboxVer |
|
private |
Shortest edge of bounding box (vertical in our case) in px.
◆ m_hasTargets
bool LimelightTarget::m_hasTargets |
|
private |
True if the camera has a target it can read.
◆ m_miscLatency
constexpr units::millisecond_t LimelightTarget::m_miscLatency {11_ms} |
|
staticconstexprprivate |
Any extra latency to account for.
◆ m_pipelineLatency
units::millisecond_t LimelightTarget::m_pipelineLatency |
|
private |
Pipeline latency contribution.
◆ m_pitch
units::degree_t LimelightTarget::m_pitch |
|
private |
Pitch of target relative to camera -20.5 to 20.5 degrees.
◆ m_skew
units::degree_t LimelightTarget::m_skew |
|
private |
The skew or rotation -90 to 0 degrees.
◆ m_yaw
units::degree_t LimelightTarget::m_yaw |
|
private |
Yaw of target relative to camera -27 to 27 degrees.
The documentation for this class was generated from the following files: