diff options
author | Stéphane Lenclud <github@lenclud.com> | 2019-04-24 23:34:36 +0200 |
---|---|---|
committer | Stéphane Lenclud <github@lenclud.com> | 2019-04-24 23:34:36 +0200 |
commit | 4039631386ae84abbf476263b28c92d91ac23b81 (patch) | |
tree | f55a4139c1ef03e20a9d7dbf5948d7964fc6db3d /tracker-easy/preview.cpp | |
parent | 77a469de95a498a4860b7da72b38508d40c2bede (diff) |
Adding support for four points model.
Can't get it to work correctly though.
Diffstat (limited to 'tracker-easy/preview.cpp')
-rw-r--r-- | tracker-easy/preview.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/tracker-easy/preview.cpp b/tracker-easy/preview.cpp index 4d6b7c61..218fca43 100644 --- a/tracker-easy/preview.cpp +++ b/tracker-easy/preview.cpp @@ -105,19 +105,17 @@ namespace EasyTracker cv::putText(iFrameRgb, aString, cv::Point(4,iFrameRgb.size().height-4), cv::FONT_HERSHEY_PLAIN, 2, cv::Scalar(0, 255, 0),2); } - void Preview::DrawCross(cv::Point aPoint) + void Preview::DrawCross(const cv::Point& aPoint, const cv::Scalar& aColor) { - constexpr int len = 9; - - static const cv::Scalar color(0, 255, 255); + constexpr int len = 9; cv::line(iFrameRgb, cv::Point(aPoint.x - len, aPoint.y), cv::Point(aPoint.x + len, aPoint.y), - color, 2); + aColor, 2); cv::line(iFrameRgb, cv::Point(aPoint.x, aPoint.y - len), cv::Point(aPoint.x, aPoint.y + len), - color, 2); + aColor, 2); } void Preview::ensure_size(cv::Mat& frame, int w, int h, int type) |