commit:     a0832cc15e6c5275cec5a34a2a215cc4428e3eee
Author:     Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 21 11:09:08 2022 +0000
Commit:     Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
CommitDate: Tue Dec  6 18:00:33 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a0832cc1

media-video/ffmpeg: allow enabling use of intel-mediasdk or oneVPL

Closes: https://bugs.gentoo.org/590752
Signed-off-by: Andrew Ammerlaan <andrewammerlaan <AT> gentoo.org>

 media-video/ffmpeg/{ffmpeg-5.1.2.ebuild => ffmpeg-5.1.2-r1.ebuild} | 5 +++--
 media-video/ffmpeg/ffmpeg-9999.ebuild                              | 5 +++--
 media-video/ffmpeg/metadata.xml                                    | 1 +
 3 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/media-video/ffmpeg/ffmpeg-5.1.2.ebuild 
b/media-video/ffmpeg/ffmpeg-5.1.2-r1.ebuild
similarity index 99%
rename from media-video/ffmpeg/ffmpeg-5.1.2.ebuild
rename to media-video/ffmpeg/ffmpeg-5.1.2-r1.ebuild
index a042eb0b277a..3467de2ac40e 100644
--- a/media-video/ffmpeg/ffmpeg-5.1.2.ebuild
+++ b/media-video/ffmpeg/ffmpeg-5.1.2-r1.ebuild
@@ -84,7 +84,7 @@ FFMPEG_FLAG_MAP=(
                # decoders
                amr:libopencore-amrwb amr:libopencore-amrnb codec2:libcodec2 
+dav1d:libdav1d fdk:libfdk-aac
                jpeg2k:libopenjpeg jpegxl:libjxl bluray:libbluray gme:libgme 
gsm:libgsm
-               libaribb24 mmal modplug:libmodplug opus:libopus libilbc librtmp 
ssh:libssh
+               libaribb24 mmal modplug:libmodplug opus:libopus qsv:libmfx 
libilbc librtmp ssh:libssh
                speex:libspeex srt:libsrt svg:librsvg nvenc:ffnvcodec
                vorbis:libvorbis vpx:libvpx zvbi:libzvbi
                # libavfilter options
@@ -248,6 +248,7 @@ RDEPEND="
        opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
        opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
        pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
+       qsv? ( media-libs/intel-mediasdk )
        rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
        samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
        sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
@@ -429,7 +430,7 @@ multilib_src_configure() {
 
        # (temporarily) disable non-multilib deps
        if ! multilib_is_native_abi; then
-               for i in librav1e libzmq ; do
+               for i in librav1e libmfx libzmq ; do
                        myconf+=( --disable-${i} )
                done
        fi

diff --git a/media-video/ffmpeg/ffmpeg-9999.ebuild 
b/media-video/ffmpeg/ffmpeg-9999.ebuild
index a042eb0b277a..016fa514d08c 100644
--- a/media-video/ffmpeg/ffmpeg-9999.ebuild
+++ b/media-video/ffmpeg/ffmpeg-9999.ebuild
@@ -84,7 +84,7 @@ FFMPEG_FLAG_MAP=(
                # decoders
                amr:libopencore-amrwb amr:libopencore-amrnb codec2:libcodec2 
+dav1d:libdav1d fdk:libfdk-aac
                jpeg2k:libopenjpeg jpegxl:libjxl bluray:libbluray gme:libgme 
gsm:libgsm
-               libaribb24 mmal modplug:libmodplug opus:libopus libilbc librtmp 
ssh:libssh
+               libaribb24 mmal modplug:libmodplug opus:libopus qsv:libvpl 
libilbc librtmp ssh:libssh
                speex:libspeex srt:libsrt svg:librsvg nvenc:ffnvcodec
                vorbis:libvorbis vpx:libvpx zvbi:libzvbi
                # libavfilter options
@@ -248,6 +248,7 @@ RDEPEND="
        opengl? ( >=virtual/opengl-7.0-r1[${MULTILIB_USEDEP}] )
        opus? ( >=media-libs/opus-1.0.2-r2[${MULTILIB_USEDEP}] )
        pulseaudio? ( >=media-sound/pulseaudio-2.1-r1[${MULTILIB_USEDEP}] )
+       qsv? ( media-libs/oneVPL )
        rubberband? ( >=media-libs/rubberband-1.8.1-r1[${MULTILIB_USEDEP}] )
        samba? ( >=net-fs/samba-3.6.23-r1[client,${MULTILIB_USEDEP}] )
        sdl? ( media-libs/libsdl2[sound,video,${MULTILIB_USEDEP}] )
@@ -429,7 +430,7 @@ multilib_src_configure() {
 
        # (temporarily) disable non-multilib deps
        if ! multilib_is_native_abi; then
-               for i in librav1e libzmq ; do
+               for i in librav1e libmfx libvpl libzmq ; do
                        myconf+=( --disable-${i} )
                done
        fi

diff --git a/media-video/ffmpeg/metadata.xml b/media-video/ffmpeg/metadata.xml
index 4bcd388dcb3a..60511928e367 100644
--- a/media-video/ffmpeg/metadata.xml
+++ b/media-video/ffmpeg/metadata.xml
@@ -44,6 +44,7 @@
                <flag name="mipsdspr1">Enables MIPS DSP ASE R1 
optimizations.</flag>
                <flag name="mipsdspr2">Enables MIPS DSP ASE R2 
optimizations.</flag>
                <flag name="mipsfpu">Enables floating point MIPS 
optimizations.</flag>
+               <flag name="qsv">Enable Intel Quick Sync Video via 
<pkg>media-libs/intel-mediasdk</pkg> (ffmpeg versions older than, and 
including, 5.1) or <pkg>media-libs/oneVPL</pkg> (ffmpeg version newer than 
5.1).</flag>
                <flag name="mmal">Enables Multi-Media Abstraction Layer (MMAL) 
decoding support: Available e.g. on the Raspberry Pi.</flag>
                <flag name="network">Enables network streaming support</flag>
                <flag name="opencl">Enable OpenCL support</flag>

Reply via email to