20 const ar_track_alvar_msgs::AlvarMarkers& including,
21 const ar_track_alvar_msgs::AlvarMarkers& excluding,
22 ar_track_alvar_msgs::AlvarMarkers& spotted)
33 spotted.markers.clear();
43 return (spotted.markers.size() > 0);
46 bool ARMarkerTracking::closest(
const ar_track_alvar_msgs::AlvarMarkers& including,
const ar_track_alvar_msgs::AlvarMarkers& excluding, ar_track_alvar_msgs::AlvarMarker&
closest)
48 double closest_dist = std::numeric_limits<double>::max();
63 return (closest_dist < std::numeric_limits<double>::max());
81 spotted.markers.clear();
90 return (spotted.markers.size() > 0);
108 spotted.markers.clear();
115 spotted.markers.push_back(m);
119 return (spotted.markers.size() > 0);
124 ar_track_alvar_msgs::AlvarMarkers spotted_markers;
125 if (
spotted(younger_than, min_confidence, spotted_markers) ==
false)
128 double closest_dist = std::numeric_limits<double>::max();
129 for (
unsigned int i = 0; i < spotted_markers.markers.size(); i++)
132 if (d < closest_dist)
135 closest = spotted_markers.markers[i];
139 return (closest_dist < std::numeric_limits<double>::max());
144 ar_track_alvar_msgs::AlvarMarkers spotted_markers;
145 if (
spotted(younger_than, min_confidence, excluding, spotted_markers) ==
false)
148 double closest_dist = std::numeric_limits<double>::max();
149 for (
unsigned int i = 0; i < spotted_markers.markers.size(); i++)
152 if (d < closest_dist)
155 closest = spotted_markers.markers[i];
159 return (closest_dist < std::numeric_limits<double>::max());
166 for (
unsigned int i = 0; i < v.markers.size(); i++)
168 if (
id == v.markers[i].id)
183 for (
unsigned int i = 0; i < v.markers.size(); i++)
185 if (
id == v.markers[i].id)
ar_track_alvar_msgs::AlvarMarkers spotted_markers_
std::vector< TrackedMarker > tracked_markers_
double distance2D(double ax, double ay, double bx, double by)
bool spotted(double younger_than, double min_confidence, ar_track_alvar_msgs::AlvarMarkers &spotted_markers)
bool included(const uint32_t id, const ar_track_alvar_msgs::AlvarMarkers &v, ar_track_alvar_msgs::AlvarMarker *e=NULL)
bool excluded(const uint32_t id, const ar_track_alvar_msgs::AlvarMarkers &v)
bool closest(double younger_than, double min_confidence, ar_track_alvar_msgs::AlvarMarker &closest_marker)