struct sharp_pos beam;
u_int16_t *data;
- static std::vector<Shape_detect::Point> reds;
- static std::vector<Shape_detect::Point> blues;
+// static std::vector<Shape_detect::Point> reds;
+// static std::vector<Shape_detect::Point> blues;
- if (reds.size() < 16) {
- get_checkerboard(blues);
- get_checkerboard(reds);
- }
+// if (reds.size() < 16) {
+// get_checkerboard(blues);
+// get_checkerboard(reds);
+// }
robot_get_est_pos(&e.x, &e.y, &e.phi);
data = s->data;
- Shape_detect shapeDet;
- std::vector<Shape_detect::Arc> arcs;
- std::vector<Shape_detect::Point> center_arcs;
-
- shapeDet.prepare(data);
- shapeDet.arc_detect(arcs);
-
- Shape_detect::Point tmpPoint;
+// Shape_detect shapeDet;
+// std::vector<Shape_detect::Arc> arcs;
+// std::vector<Shape_detect::Point> center_arcs;
+//
+// shapeDet.prepare(data);
+// shapeDet.arc_detect(arcs);
+//
+// Shape_detect::Point tmpPoint;
// double distance;
if(data[i] > 19 && data[i] < 2000) {
obst_coord(&e, &beam, data[i]/1000.0, &x, &y);
- tmpPoint.x = x;
- tmpPoint.y = y;
+// tmpPoint.x = x;
+// tmpPoint.y = y;
- if (center_arcs.size() > 0) {
- for (unsigned int j = 0; j < center_arcs.size(); j++) {
- if (point_distance(tmpPoint, center_arcs[j]) < 0.12) {
- obstacle = false;
- break;
- }
- }
- }
+// if (center_arcs.size() > 0) {
+// for (unsigned int j = 0; j < center_arcs.size(); j++) {
+// if (point_distance(tmpPoint, center_arcs[j]) < 0.12) {
+// obstacle = false;
+// break;
+// }
+// }
+// }
if (obstacle) {
obstacle_detected_at(x, y, true);