[vlc-commits] direct3d11: always lock the D3D11 context on Winstore
Steve Lhomme
git at videolan.org
Tue May 17 13:34:51 CEST 2016
vlc | branch: master | Steve Lhomme <robux4 at videolabs.io> | Tue May 17 11:14:30 2016 +0200| [bcf7c3bc7330c642e6d5e69831fe421272f7b87d] | committer: Jean-Baptiste Kempf
direct3d11: always lock the D3D11 context on Winstore
DriverConcurrentCreates is not a good indicator of thread safety
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=bcf7c3bc7330c642e6d5e69831fe421272f7b87d
---
modules/video_output/win32/direct3d11.c | 9 ++-------
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/modules/video_output/win32/direct3d11.c b/modules/video_output/win32/direct3d11.c
index c140a32..987cb2a 100644
--- a/modules/video_output/win32/direct3d11.c
+++ b/modules/video_output/win32/direct3d11.c
@@ -1217,13 +1217,8 @@ static int Direct3D11CreateResources(vout_display_t *vd, video_format_t *fmt)
HRESULT hr;
#if defined(HAVE_ID3D11VIDEODECODER) && VLC_WINSTORE_APP
- D3D11_FEATURE_DATA_THREADING threading;
- hr = ID3D11Device_CheckFeatureSupport( sys->d3ddevice, D3D11_FEATURE_THREADING, &threading, sizeof( threading ) );
- if( FAILED( hr ) || !threading.DriverConcurrentCreates )
- {
- sys->context_lock = CreateMutexEx( NULL, NULL, 0, SYNCHRONIZE );
- ID3D11Device_SetPrivateData( sys->d3ddevice, &GUID_CONTEXT_MUTEX, sizeof( sys->context_lock ), &sys->context_lock );
- }
+ sys->context_lock = CreateMutexEx( NULL, NULL, 0, SYNCHRONIZE );
+ ID3D11Device_SetPrivateData( sys->d3ddevice, &GUID_CONTEXT_MUTEX, sizeof( sys->context_lock ), &sys->context_lock );
#endif
hr = UpdateBackBuffer(vd);
More information about the vlc-commits
mailing list