Commit f39ca018 authored by Steve Lhomme's avatar Steve Lhomme Committed by Jean-Baptiste Kempf

d3d11va: only create the device with the debug flag in debug builds

With a debugger attached.
In UWP we can assume it's present with MS build and no debug with mingw
Signed-off-by: Jean-Baptiste Kempf's avatarJean-Baptiste Kempf <>
parent fc421acf
......@@ -427,8 +427,17 @@ static int D3dCreateDevice(vlc_va_t *va)
#if !defined(NDEBUG) //&& defined(_MSC_VER)
creationFlags |= D3D11_CREATE_DEVICE_DEBUG;
#if !defined(NDEBUG)
if (IsDebuggerPresent())
HINSTANCE sdklayer_dll = LoadLibrary(TEXT("d3d11_1sdklayers.dll"));
if (sdklayer_dll) {
creationFlags |= D3D11_CREATE_DEVICE_DEBUG;
/* */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment