summaryrefslogtreecommitdiff
path: root/libavcodec/dxva2_internal.h
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/dxva2_internal.h')
-rw-r--r--libavcodec/dxva2_internal.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/libavcodec/dxva2_internal.h b/libavcodec/dxva2_internal.h
index 426de9dc16..d5cc01ef4f 100644
--- a/libavcodec/dxva2_internal.h
+++ b/libavcodec/dxva2_internal.h
@@ -27,6 +27,9 @@
#include "config.h"
+/* define the proper COM entries before forcing desktop APIs */
+#include <objbase.h>
+
#if CONFIG_DXVA2
#include "dxva2.h"
#endif
@@ -35,6 +38,10 @@
#endif
#if HAVE_DXVA_H
+/* dxva.h defines nothing otherwise but it works */
+#undef WINAPI_FAMILY
+#define WINAPI_FAMILY WINAPI_FAMILY_DESKTOP_APP
+#define _CRT_BUILD_DESKTOP_APP 0
#include <dxva.h>
#endif