Commit dafefe68 authored by oscar's avatar oscar

提交修改

parent c7753fea
......@@ -453,6 +453,8 @@ void TrackingRos::TrackingCameraCallBackFunc(const jfx_common_msgs::InferResesCo
int y1 = camera_msg.location[1];
int x2 = camera_msg.location[2];
int y2 = camera_msg.location[3];
float area = float(abs(x1 - x2) * abs(y1 - y2));
float MAXAREA = 200 * 200;
float prob = camera_msg.prob;
int num_class = camera_msg.num_class;
float bottom_center_x = (float(x1) + float(x2)) / 2;
......@@ -465,12 +467,16 @@ void TrackingRos::TrackingCameraCallBackFunc(const jfx_common_msgs::InferResesCo
}
else if (i == 1)
{
if (area < MAXAREA)
continue;
bottom_center_x = x1;
bottom_center_y = y1;
get_camera_right_tolidar_loc(bottom_center_x, bottom_center_y, x, y);
}
else if (i == 2)
{
if (area < MAXAREA)
continue;
bottom_center_x = x2;
bottom_center_y = y2;
get_camera_left_tolidar_loc(bottom_center_x, bottom_center_y, x, y);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment