ASCO Aerial Autonomy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
ClosestTrackingStrategy Class Reference

A tracking strategy that locks on to the closest target when initialized. More...

#include <closest_tracking_strategy.h>

Inheritance diagram for ClosestTrackingStrategy:
Inheritance graph
[legend]
Collaboration diagram for ClosestTrackingStrategy:
Collaboration graph
[legend]

Public Member Functions

 ClosestTrackingStrategy (uint32_t max_tracking_retries=20)
 Constructor. More...
 
virtual bool initialize (const std::unordered_map< uint32_t, Position > &tracking_vectors)
 Initialize the strategy from a group of targets. Locks on to closest target. More...
 
virtual bool getTrackingVector (const std::unordered_map< uint32_t, Position > &tracking_vectors, std::tuple< uint32_t, Position > &tracking_vector)
 Get the tracking vector for the tracked target. More...
 

Detailed Description

A tracking strategy that locks on to the closest target when initialized.

Constructor & Destructor Documentation

ClosestTrackingStrategy::ClosestTrackingStrategy ( uint32_t  max_tracking_retries = 20)
inline

Constructor.

Parameters
max_tracking_retriesNumber of times to retry tracking before lock is lost

Member Function Documentation

bool ClosestTrackingStrategy::getTrackingVector ( const std::unordered_map< uint32_t, Position > &  tracking_vectors,
std::tuple< uint32_t, Position > &  tracking_vector 
)
virtual

Get the tracking vector for the tracked target.

Parameters
tracking_vectorsThe vectors to the tracked targets
tracking_vectorTracked target which was closest when initialized
Returns
True if successful, false otherwise

Implements TrackingStrategy.

bool ClosestTrackingStrategy::initialize ( const std::unordered_map< uint32_t, Position > &  tracking_vectors)
virtual

Initialize the strategy from a group of targets. Locks on to closest target.

Parameters
tracking_vectorsThe vectors to the tracked targets
Returns
True if successful, false otherwise

Implements TrackingStrategy.


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