Martin Storsjö <[email protected]> writes: > On Tue, 26 Jun 2012, Måns Rullgård wrote: > >> Martin Storsjö <[email protected]> writes: >> >>> From: "Ronald S. Bultje" <[email protected]> >>> >>> Apparently, some build environments require dxva.h even for dxva2, >>> while others lack this header entirely. Including it conditionally >>> allows building in both cases. >>> --- >>> This is slightly messier since we need to include d3d9.h before >>> the dxva.h header can be included properly, but avoids having to >>> change the installed header. >>> >>> configure | 2 ++ >>> libavcodec/dxva2_internal.h | 7 +++++++ >>> 2 files changed, 9 insertions(+) >>> >>> diff --git a/configure b/configure >>> index aa1856d..3442797 100755 >>> --- a/configure >>> +++ b/configure >>> @@ -1070,6 +1070,7 @@ HAVE_LIST=" >>> dlfcn_h >>> dlopen >>> dos_paths >>> + dxva_h >>> ebp_available >>> ebx_available >>> exp2 >>> @@ -2866,6 +2867,7 @@ check_func_headers windows.h Sleep >>> check_func_headers windows.h VirtualAlloc >>> >>> check_header dlfcn.h >>> +check_header dxva.h >>> check_header dxva2api.h >>> check_header malloc.h >>> check_header poll.h >>> diff --git a/libavcodec/dxva2_internal.h b/libavcodec/dxva2_internal.h >>> index 57fc7bd..c9f3acf 100644 >>> --- a/libavcodec/dxva2_internal.h >>> +++ b/libavcodec/dxva2_internal.h >>> @@ -25,6 +25,13 @@ >>> >>> #define _WIN32_WINNT 0x0600 >>> #define COBJMACROS >>> + >>> +#include "config.h" >>> +#if HAVE_DXVA_H >>> +#include <d3d9.h> >>> +#include <dxva.h> >>> +#endif >> >> Is it safe to assume that d3d9.h is present? > > I would think so, at least dxva2.h includes it too.
Does dxva.h have to be included before dxva2.h? -- Måns Rullgård [email protected] _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
