summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_tracker_pt/video_widget.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-04-27 18:52:37 +0200
committerStanislaw Halik <sthalik@misaki.pl>2013-04-27 18:52:37 +0200
commit5fdf8b92e78b2a5690ba0e9642c0d68d8b2e4495 (patch)
tree6a4cab7baf5311fd1e869de329b51514a88aff53 /ftnoir_tracker_pt/video_widget.cpp
parentf44108df519d4aae5caa0bce62c9f54ca5b8c47a (diff)
Fix embarassing locking but propagated through the codebase :(
Diffstat (limited to 'ftnoir_tracker_pt/video_widget.cpp')
-rw-r--r--ftnoir_tracker_pt/video_widget.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/ftnoir_tracker_pt/video_widget.cpp b/ftnoir_tracker_pt/video_widget.cpp
index e6d1e24c..a13542ba 100644
--- a/ftnoir_tracker_pt/video_widget.cpp
+++ b/ftnoir_tracker_pt/video_widget.cpp
@@ -14,7 +14,7 @@ using namespace std;
void VideoWidget::update_image(Mat frame, std::auto_ptr< vector<Vec2f> >)
{
- QMutexLocker((QMutex*)&mtx);
+ QMutexLocker foo(&mtx);
if (frame.channels() != 3 && frame.channels() != 1)
return;
@@ -47,9 +47,6 @@ void VideoWidget::update_image(Mat frame, std::auto_ptr< vector<Vec2f> >)
data[y * pitch + x * 3 + 2] = src[pos];
}
}
- if (qframe.size() == size() || (qframe.width() <= this->width() && qframe.height() <= this->height())) {
- }
- else
- qframe = qframe.scaled(size(), Qt::IgnoreAspectRatio, Qt::FastTransformation);
+ qframe = qframe.scaled(size(), Qt::IgnoreAspectRatio, Qt::FastTransformation);
pixmap = QPixmap::fromImage(qframe);
}