Commit 09c7c972 authored by oscar's avatar oscar

提交更新

parent d0f89c13
......@@ -67,14 +67,14 @@ Track3D::Track3D():BaseTrack(10, 7)
float calcIOU(cv::RotatedRect rect1, cv::RotatedRect rect2) {
float areaRect1 = rect1.size.width * rect1.size.height;
float areaRect2 = rect2.size.width * rect2.size.height;
vector<cv::Point2f> vertices;
std::vector<cv::Point2f> vertices;
int intersectionType = cv::rotatedRectangleIntersection(rect1, rect2, vertices);
if (vertices.size() == 0)
return 0.0;
else
{
vector<cv::Point2f> order_pts;
std::vector<cv::Point2f> order_pts;
// 找到交集(交集的区域),对轮廓的各个点进行排序
cv::convexHull(cv::Mat(vertices), order_pts, true);
......
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