mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
qsv: remove mfx/ prefix from mfx headers
The following Cflags has been added to libmfx.pc, so mfx/ prefix is no longer needed when including mfx headers in FFmpeg. Cflags: -I${includedir} -I${includedir}/mfx Some old versions of libmfx have the following Cflags in libmfx.pc Cflags: -I${includedir} We may add -I${includedir}/mfx to CFLAGS when running 'configure --enable-libmfx' for old versions of libmfx, if so, mfx headers without mfx/ prefix can be included too. If libmfx comes without pkg-config support, we may do a small change to the settings of the environment(e.g. set -I/opt/intel/mediasdk/include/mfx instead of -I/opt/intel/mediasdk/include to CFLAGS), then the build can find the mfx headers without mfx/ prefix After applying this change, we won't need to change #include for mfx headers when mfx headers are installed under a new directory. This is in preparation for oneVPL support (mfx headers in oneVPL are installed under vpl directory)
This commit is contained in:
parent
7c713ab42c
commit
3e61b7dd7f
19
configure
vendored
19
configure
vendored
@ -6583,15 +6583,20 @@ enabled liblensfun && require_pkg_config liblensfun lensfun lensfun.h lf_
|
||||
# Media SDK or Intel Media Server Studio, these don't come with
|
||||
# pkg-config support. Instead, users should make sure that the build
|
||||
# can find the libraries and headers through other means.
|
||||
enabled libmfx && { { check_pkg_config libmfx "libmfx >= 1.28 libmfx < 2.0" "mfx/mfxvideo.h" MFXInit ||
|
||||
{ require libmfx "mfx/mfxvideo.h mfx/mfxdefs.h" MFXInit "-llibmfx $advapi32_extralibs" &&
|
||||
{ test_cpp_condition mfx/mfxdefs.h "MFX_VERSION >= 1028 && MFX_VERSION < 2000" || die "ERROR: libmfx version must be >= 1.28 and < 2.0"; } &&
|
||||
warn "using libmfx without pkg-config"; } } &&
|
||||
warn "build FFmpeg against libmfx 1.x, obsolete features of libmfx such as OPAQUE memory,\n"\
|
||||
"multi-frame encode, user plugins and LA_EXT rate control mode are enabled"; }
|
||||
enabled libmfx && { { check_pkg_config libmfx "libmfx >= 1.28 libmfx < 2.0" "mfxvideo.h" MFXInit ||
|
||||
# Some old versions of libmfx have the following settings in libmfx.pc:
|
||||
# includedir=/usr/include
|
||||
# Cflags: -I${includedir}
|
||||
# So add -I${includedir}/mfx to CFLAGS
|
||||
{ check_pkg_config libmfx "libmfx >= 1.28 libmfx < 2.0" "mfx/mfxvideo.h" MFXInit && add_cflags -I${libmfx_incdir}/mfx; } ||
|
||||
{ require libmfx "mfxvideo.h mfxdefs.h" MFXInit "-llibmfx $advapi32_extralibs" &&
|
||||
{ test_cpp_condition mfxdefs.h "MFX_VERSION >= 1028 && MFX_VERSION < 2000" || die "ERROR: libmfx version must be >= 1.28 and < 2.0"; } &&
|
||||
warn "using libmfx without pkg-config"; } } &&
|
||||
warn "build FFmpeg against libmfx 1.x, obsolete features of libmfx such as OPAQUE memory,\n"\
|
||||
"multi-frame encode, user plugins and LA_EXT rate control mode are enabled"; }
|
||||
|
||||
if enabled libmfx; then
|
||||
check_cc MFX_CODEC_VP9 "mfx/mfxdefs.h mfx/mfxstructures.h" "MFX_CODEC_VP9"
|
||||
check_cc MFX_CODEC_VP9 "mfxdefs.h mfxstructures.h" "MFX_CODEC_VP9"
|
||||
fi
|
||||
|
||||
enabled libmodplug && require_pkg_config libmodplug libmodplug libmodplug/modplug.h ModPlug_Load
|
||||
|
@ -18,9 +18,9 @@
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfx/mfxplugin.h>
|
||||
#include <mfx/mfxjpeg.h>
|
||||
#include <mfxvideo.h>
|
||||
#include <mfxplugin.h>
|
||||
#include <mfxjpeg.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
@ -38,7 +38,7 @@
|
||||
|
||||
#define MFX_IMPL_VIA_MASK(impl) (0x0f00 & (impl))
|
||||
|
||||
#include "mfx/mfxvp8.h"
|
||||
#include "mfxvp8.h"
|
||||
|
||||
int ff_qsv_codec_id_to_mfx(enum AVCodecID codec_id)
|
||||
{
|
||||
|
@ -21,7 +21,7 @@
|
||||
#ifndef AVCODEC_QSV_H
|
||||
#define AVCODEC_QSV_H
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/buffer.h"
|
||||
|
||||
|
@ -39,7 +39,7 @@
|
||||
#include "libavutil/hwcontext_vaapi.h"
|
||||
#endif
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/frame.h"
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
#include <string.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/fifo.h"
|
||||
|
@ -25,7 +25,7 @@
|
||||
|
||||
#include <string.h>
|
||||
#include <sys/types.h>
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/hwcontext.h"
|
||||
|
@ -26,7 +26,7 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/avutil.h"
|
||||
#include "libavutil/fifo.h"
|
||||
|
@ -24,7 +24,7 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/opt.h"
|
||||
|
@ -22,7 +22,7 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/opt.h"
|
||||
|
@ -22,7 +22,7 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/opt.h"
|
||||
|
@ -22,7 +22,7 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/opt.h"
|
||||
|
@ -22,7 +22,7 @@
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "libavutil/common.h"
|
||||
#include "libavutil/opt.h"
|
||||
|
@ -24,7 +24,7 @@
|
||||
#ifndef AVFILTER_QSVVPP_H
|
||||
#define AVFILTER_QSVVPP_H
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "avfilter.h"
|
||||
#include "libavutil/fifo.h"
|
||||
|
@ -21,7 +21,7 @@
|
||||
* deinterlace video filter - QSV
|
||||
*/
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
@ -21,7 +21,7 @@
|
||||
* scale video filter - QSV
|
||||
*/
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
@ -47,7 +47,7 @@
|
||||
|
||||
#if HAVE_OPENCL_VAAPI_INTEL_MEDIA
|
||||
#if CONFIG_LIBMFX
|
||||
#include <mfx/mfxstructures.h>
|
||||
#include <mfxstructures.h>
|
||||
#endif
|
||||
#include <va/va.h>
|
||||
#include <CL/cl_va_api_media_sharing_intel.h>
|
||||
|
@ -20,7 +20,7 @@
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
#include "config.h"
|
||||
|
||||
|
@ -19,7 +19,7 @@
|
||||
#ifndef AVUTIL_HWCONTEXT_QSV_H
|
||||
#define AVUTIL_HWCONTEXT_QSV_H
|
||||
|
||||
#include <mfx/mfxvideo.h>
|
||||
#include <mfxvideo.h>
|
||||
|
||||
/**
|
||||
* @file
|
||||
|
Loading…
Reference in New Issue
Block a user