Skip to content

Truly independent web browser

Meta: Enable Vulkan video decoding and libdrm in FFmpeg

Zaggy10249a0c6bca70ea
diff --git a/Meta/CMake/flatpak/org.ladybird.Ladybird.json b/Meta/CMake/flatpak/org.ladybird.Ladybird.json
index a2ddb0f6554..bcf0bb75970 100644
--- a/Meta/CMake/flatpak/org.ladybird.Ladybird.json
+++ b/Meta/CMake/flatpak/org.ladybird.Ladybird.json
@@ -615,7 +615,7 @@
"name": "ffmpeg",
"buildsystem": "simple",
"build-commands": [
- "./configure --prefix=/app --libdir=/app/lib --enable-shared --disable-static --enable-pic --disable-doc --enable-debug --enable-runtime-cpudetect --disable-autodetect --build-suffix=-ladybird --disable-everything --disable-network --disable-ffmpeg --disable-ffplay --disable-ffprobe --enable-avcodec --disable-avdevice --disable-avformat --disable-avfilter --enable-swresample --disable-swscale --enable-libdav1d --enable-zlib --enable-decoder=vp8,vp9,libdav1d,theora,vorbis,opus,flac,mp3float,pcm_u8,pcm_s16le,pcm_s24le,pcm_s32le,pcm_f32le,pcm_alaw,pcm_mulaw --enable-parser=vp8,vp9,av1,mpegaudio --disable-optimizations",
+ "./configure --prefix=/app --libdir=/app/lib --enable-shared --disable-static --enable-pic --disable-doc --enable-debug --enable-runtime-cpudetect --disable-autodetect --build-suffix=-ladybird --disable-everything --disable-network --disable-ffmpeg --disable-ffplay --disable-ffprobe --enable-avcodec --disable-avdevice --disable-avformat --disable-avfilter --enable-swresample --disable-swscale --enable-libdav1d --enable-zlib --enable-vulkan --enable-libdrm --enable-decoder=vp8,vp9,av1,libdav1d,theora,vorbis,opus,flac,mp3float,pcm_u8,pcm_s16le,pcm_s24le,pcm_s32le,pcm_f32le,pcm_alaw,pcm_mulaw --enable-hwaccel=vp9_vulkan,av1_vulkan --enable-parser=vp8,vp9,av1,mpegaudio --disable-optimizations",
"make -j$(nproc) V=1",
"make install"
],
diff --git a/Meta/CMake/vcpkg/overlay-ports/ffmpeg/portfile.cmake b/Meta/CMake/vcpkg/overlay-ports/ffmpeg/portfile.cmake
index bb94499dd36..9f1a4470461 100644
--- a/Meta/CMake/vcpkg/overlay-ports/ffmpeg/portfile.cmake
+++ b/Meta/CMake/vcpkg/overlay-ports/ffmpeg/portfile.cmake
@@ -281,6 +281,9 @@ if("ladybird-components" IN_LIST FEATURES)
set(OPTIONS "${OPTIONS} --disable-everything --disable-network")
set(OPTIONS "${OPTIONS} --enable-decoder=vp8,vp9,libdav1d,theora,vorbis,opus,flac,mp3float,pcm_u8,pcm_s16le,pcm_s24le,pcm_s32le,pcm_f32le,pcm_alaw,pcm_mulaw")
set(OPTIONS "${OPTIONS} --enable-parser=vp8,vp9,av1,mpegaudio")
+ if("vulkan" IN_LIST FEATURES)
+ set(OPTIONS "${OPTIONS} --enable-decoder=av1 --enable-hwaccel=vp9_vulkan,av1_vulkan --enable-libdrm")
+ endif()
endif()
if("swscale" IN_LIST FEATURES)
diff --git a/Meta/CMake/vcpkg/overlay-ports/ffmpeg/vcpkg.json b/Meta/CMake/vcpkg/overlay-ports/ffmpeg/vcpkg.json
index 52cb8575903..512cba382d3 100644
--- a/Meta/CMake/vcpkg/overlay-ports/ffmpeg/vcpkg.json
+++ b/Meta/CMake/vcpkg/overlay-ports/ffmpeg/vcpkg.json
@@ -1,7 +1,7 @@
{
"name": "ffmpeg",
"version": "9.0.2",
- "port-version": 4,
+ "port-version": 5,
"description": [
"A library to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created.",
"FFmpeg is the leading multimedia framework, able to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created. It supports the most obscure ancient formats up to the cutting edge. No matter if they were designed by some standards committee, the community or a corporation. It is also highly portable: FFmpeg compiles, runs, and passes our testing infrastructure FATE across Linux, Mac OS X, Microsoft Windows, the BSDs, Solaris, etc. under a wide variety of build environments, machine architectures, and configurations."
diff --git a/vcpkg.json b/vcpkg.json
index 14b321f1743..59783e697b6 100644
--- a/vcpkg.json
+++ b/vcpkg.json
@@ -47,7 +47,11 @@
"swresample",
"dav1d",
"zlib",
- "ladybird-components"
+ "ladybird-components",
+ {
+ "name": "vulkan",
+ "platform": "linux"
+ }
]
},
{