GT RoboCup SSL
Soccer software, robot firmware
Camera Class Reference

Contains all the kalman balls/robots for the specific camera. More...

Public Member Functions

 Camera ()
 Creates an invalid camera.
 
 Camera (int cameraID)
 Creates a valid camera with a specific id. More...
 
bool getIsValid () const
 Returns whether this camera is valid and initialized correctly.
 
void processBallBounce (const std::vector< WorldRobot > &yellowRobots, const std::vector< WorldRobot > &blueRobots)
 Tries to predict bounces off the best known estimation of the robots. More...
 
void updateWithFrame (RJ::Time calcTime, const std::vector< CameraBall > &ballList, const std::vector< std::list< CameraRobot >> &yellowRobotList, const std::vector< std::list< CameraRobot >> &blueRobotList, const WorldBall &previousWorldBall, const std::vector< WorldRobot > &previousYellowWorldRobots, const std::vector< WorldRobot > &previousBlueWorldRobots)
 Updates all the filters with the latest camera frame data for this camera. More...
 
void updateWithoutFrame (RJ::Time calcTime)
 Updates all the filters without any new data from this specific camera. More...
 
const std::list< KalmanBall > & getKalmanBalls () const
 
const std::vector< std::list< KalmanRobot > > & getKalmanRobotsYellow () const
 
const std::vector< std::list< KalmanRobot > > & getKalmanRobotsBlue () const
 

Static Public Member Functions

static void createConfiguration (Configuration *cfg)
 

Detailed Description

Contains all the kalman balls/robots for the specific camera.

Constructor & Destructor Documentation

◆ Camera()

Camera::Camera ( int  cameraID)

Creates a valid camera with a specific id.

Parameters
cameraIDID of this camera

Member Function Documentation

◆ getKalmanBalls()

const std::list< KalmanBall > & Camera::getKalmanBalls ( ) const
Returns
A list of the kalman balls associated with the camera

◆ getKalmanRobotsBlue()

const std::vector< std::list< KalmanRobot > > & Camera::getKalmanRobotsBlue ( ) const
Returns
A vector of blue kalman robot lists

◆ getKalmanRobotsYellow()

const std::vector< std::list< KalmanRobot > > & Camera::getKalmanRobotsYellow ( ) const
Returns
A vector of yellow kalman robot lists

◆ processBallBounce()

void Camera::processBallBounce ( const std::vector< WorldRobot > &  yellowRobots,
const std::vector< WorldRobot > &  blueRobots 
)

Tries to predict bounces off the best known estimation of the robots.

Parameters
yellowRobotsList of the yellow world robots in the world class
blueRobotsList of blue world robots in the world class

◆ updateWithFrame()

void Camera::updateWithFrame ( RJ::Time  calcTime,
const std::vector< CameraBall > &  ballList,
const std::vector< std::list< CameraRobot >> &  yellowRobotList,
const std::vector< std::list< CameraRobot >> &  blueRobotList,
const WorldBall previousWorldBall,
const std::vector< WorldRobot > &  previousYellowWorldRobots,
const std::vector< WorldRobot > &  previousBlueWorldRobots 
)

Updates all the filters with the latest camera frame data for this camera.

Parameters
calcTimeTime of this calculation
ballListUnsorted list of balls measurements
yellowRobotListList of yellow robots sorted by id
blueRobotListList of blue robots sorted by id
previousWorldBallBest idea of current ball pos/vel to init velocity of new filters
previousYellowWorldRobotsBest idea of current robots pos/vel to init velocity of new filters
previousBlueWorldRobotsBest idea of current robots pos/vel to init velocity of new filters

Note: Call either this OR updateWithoutFrame once an iteration

◆ updateWithoutFrame()

void Camera::updateWithoutFrame ( RJ::Time  calcTime)

Updates all the filters without any new data from this specific camera.

Parameters
calcTimeTime of this calculation

Note: Call either this OR updateWithFrame once an iteration


The documentation for this class was generated from the following files: