vlc | branch: master | Steve Lhomme <[email protected]> | Thu Jan 19 11:10:41 2017 +0100| [6c6bd02d9c9e9c7ecb2c66250c4e53561e5f417d] | committer: Jean-Baptiste Kempf
direct3d11: don't keep the context locked during the swapchain Present() call Signed-off-by: Jean-Baptiste Kempf <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6c6bd02d9c9e9c7ecb2c66250c4e53561e5f417d --- modules/video_output/win32/direct3d11.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/modules/video_output/win32/direct3d11.c b/modules/video_output/win32/direct3d11.c index 82cff6e..00c2e09 100644 --- a/modules/video_output/win32/direct3d11.c +++ b/modules/video_output/win32/direct3d11.c @@ -1046,6 +1046,13 @@ static void Display(vout_display_t *vd, picture_t *picture, subpicture_t *subpic } } +#if defined(HAVE_ID3D11VIDEODECODER) + if (sys->context_lock != INVALID_HANDLE_VALUE && is_d3d11_opaque(picture->format.i_chroma)) + { + ReleaseMutex( sys->context_lock ); + } +#endif + DXGI_PRESENT_PARAMETERS presentParams; memset(&presentParams, 0, sizeof(presentParams)); HRESULT hr = IDXGISwapChain1_Present1(sys->dxgiswapChain, 0, 0, &presentParams); @@ -1054,11 +1061,6 @@ static void Display(vout_display_t *vd, picture_t *picture, subpicture_t *subpic /* TODO device lost */ msg_Dbg(vd, "SwapChain Present failed. (hr=0x%lX)", hr); } -#if defined(HAVE_ID3D11VIDEODECODER) - if( is_d3d11_opaque(picture->format.i_chroma) && sys->context_lock != INVALID_HANDLE_VALUE) { - ReleaseMutex( sys->context_lock ); - } -#endif picture_Release(picture); if (subpicture) _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
