summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2014-12-21 12:38:08 +0100
committerStanislaw Halik <sthalik@misaki.pl>2014-12-21 13:30:05 +0100
commitd42a9b7051051340c655417b157191d6a927044e (patch)
tree5daeafc22839cc5e021165185b0fcf96eb6e670a /ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
parent5996bd4e9a567a73882d12ad7a6708f93b06bb69 (diff)
pt: show model center in different color to avoid confusion
Diffstat (limited to 'ftnoir_tracker_pt/ftnoir_tracker_pt.cpp')
-rw-r--r--ftnoir_tracker_pt/ftnoir_tracker_pt.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp b/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
index 11814756..7be8ac03 100644
--- a/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
+++ b/ftnoir_tracker_pt/ftnoir_tracker_pt.cpp
@@ -90,10 +90,13 @@ void Tracker::run()
points.push_back(p_);
}
- for (auto p : points)
+ for (int i = 0; i < points.size(); i++)
{
+ auto& p = points[i];
auto p2 = cv::Point(p[0] * frame.cols + frame.cols/2, -p[1] * frame.cols + frame.rows/2);
cv::Scalar color(0, 255, 0);
+ if (i == points.size()-1)
+ color = cv::Scalar(0, 0, 255);
cv::line(frame,
cv::Point(p2.x - 20, p2.y),
cv::Point(p2.x + 20, p2.y),