Minimal class that represents a Point of Interest by an ID and stores its successive locations $Author: Martin. More...
#include <Feature.h>
Public Types | |
typedef long | Id |
typedef boost::tuple< double, double, double > | Location |
typedef std::pair< Location, Location > | LocationPair |
typedef boost::shared_ptr< Feature > | Ptr |
typedef std::vector< Location > | Trajectory |
Public Member Functions | |
void | addLocation (Location fl_in) |
Ptr | clone () const |
Feature () | |
Feature (int feature_birthday, Location first_fl_in) | |
Feature (int feature_birthday, Location first_fl_in, Id f_id) | |
Feature (const Feature &f) | |
size_t | getFeatureAge () const |
int | getFeatureBirthday () const |
Location | getFirstLocation () const |
Id | getId () const |
Location | getLastLocation () const |
double | getLastX () const |
double | getLastY () const |
double | getLastZ () const |
Location | getNextToLastLocation () const |
Location | getNToLastLocation (int frames_to_last) const |
const Trajectory & | getTrajectory () const |
LocationPair | getTwoLastLocations () const |
void | setFeatureBirthday (int feature_birthday) |
virtual | ~Feature () |
Protected Member Functions | |
virtual Feature * | doClone () const |
Protected Attributes | |
int | _birthday |
Location | _first_location |
Id | _id |
Trajectory | _trajectory |
Static Protected Attributes | |
static Id | _feature_id_generator = 1 |
Minimal class that represents a Point of Interest by an ID and stores its successive locations $Author: Martin.
typedef long omip::Feature::Id |
typedef boost::tuple<double, double, double> omip::Feature::Location |
typedef std::pair<Location, Location> omip::Feature::LocationPair |
typedef boost::shared_ptr<Feature> omip::Feature::Ptr |
typedef std::vector<Location> omip::Feature::Trajectory |
Feature::Feature | ( | ) |
Feature constructor
Definition at line 9 of file Feature.cpp.
Feature::Feature | ( | int | feature_birthday, |
Location | first_fl_in | ||
) |
Feature constructor
feature_birthday | - Time stamp when the Feature was initially detected |
first_fl_in | - First Feature Location |
Definition at line 15 of file Feature.cpp.
Feature::Feature | ( | const Feature & | f | ) |
|
virtual |
Default destructor
Definition at line 37 of file Feature.cpp.
void Feature::addLocation | ( | Location | fl_in | ) |
Add a new Location of this Feature
fl_in | - New location of this Feature |
Definition at line 47 of file Feature.cpp.
Feature::Ptr Feature::clone | ( | ) | const |
Create a new Feature object as a copy of this and pass a pointer
Definition at line 42 of file Feature.cpp.
|
inlineprotectedvirtual |
size_t Feature::getFeatureAge | ( | ) | const |
Get the age of this Feature
Definition at line 126 of file Feature.cpp.
int Feature::getFeatureBirthday | ( | ) | const |
Get this Feature's Birthday (frame number)
Definition at line 131 of file Feature.cpp.
Feature::Location Feature::getFirstLocation | ( | ) | const |
Get the first Location of this Feature
Definition at line 61 of file Feature.cpp.
Feature::Id Feature::getId | ( | ) | const |
Feature::Location Feature::getLastLocation | ( | ) | const |
Get the last Location of this Feature
Definition at line 66 of file Feature.cpp.
double Feature::getLastX | ( | ) | const |
Get the x coordinate of the last Location of this Feature
Definition at line 136 of file Feature.cpp.
double Feature::getLastY | ( | ) | const |
Get the y coordinate of the last Location of this Feature
Definition at line 141 of file Feature.cpp.
double Feature::getLastZ | ( | ) | const |
Get the z coordinate of the last Location of this Feature
Definition at line 146 of file Feature.cpp.
Feature::Location Feature::getNextToLastLocation | ( | ) | const |
Get the next to last Location of this Feature
Definition at line 81 of file Feature.cpp.
Feature::Location Feature::getNToLastLocation | ( | int | frames_to_last | ) | const |
Get the Location of this Feature N frames before the last Location
frames_to_last | - Number of frames before the last frame where we want the Location from |
Definition at line 101 of file Feature.cpp.
const Feature::Trajectory & Feature::getTrajectory | ( | ) | const |
Get the Trajectory of this Feature
Definition at line 116 of file Feature.cpp.
Feature::LocationPair Feature::getTwoLastLocations | ( | ) | const |
Get the two last Locations (last and next to last) of this Feature
Definition at line 96 of file Feature.cpp.
void Feature::setFeatureBirthday | ( | int | feature_birthday | ) |
Set this Feature's Birthday (frame number)
feature_birthday | - Birthday of this Feature as the frame when it was initially detected |
Definition at line 151 of file Feature.cpp.
|
staticprotected |
|
protected |