summaryrefslogtreecommitdiffstats
path: root/src/plugins/winrt
diff options
context:
space:
mode:
authorMaurice Kalinowski <maurice.kalinowski@qt.io>2016-06-08 11:52:40 +0200
committerMaurice Kalinowski <maurice.kalinowski@qt.io>2016-06-08 11:09:36 +0000
commitbff19dbe6733d245adc2daf79fe3bab017abb1e2 (patch)
tree292af88725fc2377679622b3539323e3627283cb /src/plugins/winrt
parent20299cfc4a67647bbe93abd7e171d273c3ac7bee (diff)
winrt: Fix synchronization problems to render thread
QWinRTAbstractVideoRendererControl::setActive was using QThread::requestInterrupt previously to indicate to the render thread that it is supposed to quit. However, when switching cameras you cannot tell the render thread to continue rendering. Instead start() is called and then the render thread recognized the previous interrupt request, resulting in a quit and no further rendering happening. Instead we wait for the render thread to complete by using shutdown(). Task-number: QTBUG-53722 Change-Id: Ibee2ed4f64400ca14c788984a73df4be0653ed2b Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Diffstat (limited to 'src/plugins/winrt')
-rw-r--r--src/plugins/winrt/qwinrtabstractvideorenderercontrol.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/winrt/qwinrtabstractvideorenderercontrol.cpp b/src/plugins/winrt/qwinrtabstractvideorenderercontrol.cpp
index 941902dd7..f109dc4cb 100644
--- a/src/plugins/winrt/qwinrtabstractvideorenderercontrol.cpp
+++ b/src/plugins/winrt/qwinrtabstractvideorenderercontrol.cpp
@@ -360,7 +360,7 @@ void QWinRTAbstractVideoRendererControl::setActive(bool active)
return;
}
- d->renderThread.requestInterruption();
+ shutdown();
if (d->surface && d->surface->isActive())
d->surface->stop();
}