Android: flush the current video frame when the video output is reset.
The texture renderer could end up in a situation where a frame could be scheduled to be rendered after the renderer was reset. Change-Id: Ie6b6c9d0b5f5851f14aa6eb5f8421196aff8c691 Reviewed-by: Christian Stromme <christian.stromme@qt.io>
This commit is contained in:
@@ -284,6 +284,10 @@ void QAndroidTextureVideoOutput::stop()
|
||||
|
||||
void QAndroidTextureVideoOutput::reset()
|
||||
{
|
||||
// flush pending frame
|
||||
if (m_surface)
|
||||
m_surface->present(QVideoFrame());
|
||||
|
||||
clearSurfaceTexture();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user