[vlc-commits] [Git][videolan/vlc][3.0.x] 6 commits: qsv: avoid displaying NULL
Steve Lhomme (@robUx4)
gitlab at videolan.org
Sat Jul 25 12:53:21 UTC 2026
Steve Lhomme pushed to branch 3.0.x at VideoLAN / VLC
Commits:
e40e5de4 by Alexandre Janniaux at 2026-07-25T11:39:16+00:00
qsv: avoid displaying NULL
(cherry picked from commit 57994187013fb362f7dcf5a5a2bd32177410df36)
Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>
- - - - -
0eede828 by Steve Lhomme at 2026-07-25T11:39:16+00:00
contrib: mfx: update to 1.35.1
It requires some newly allowed API's (library loading, registry access)
to compile and link properly.
The new UWP patches have been merged upstream.
(cherry picked from commit ddf30060ea25a9dfbbbf9061efcd9acc253b5875)
Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>
- - - - -
688235a8 by Nicolas Chauvet at 2026-07-25T11:39:16+00:00
contrib: rename retired mfx to vpl
(cherry picked from commit 3d80d93f0c49d34707d129e6b5f2e9a304e084ba)
Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>
- - - - -
b6349fd0 by Steve Lhomme at 2026-07-25T11:39:16+00:00
contrib: vpl: fix C++ library listed in the .pc file
(cherry picked from commit db48f4043e04d891d95f1bba1846c7d03ae13a0e)
Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>
- - - - -
dcd1e9f4 by Nicolas Chauvet at 2026-07-25T11:39:16+00:00
mfx: switch from retired mfx to vpl
Media Framework SDK is retired in favor of Video Processing Library for intel hardware encoding.
Changing the included header and pkgconfig is enough.
Signed-off-by: Nicolas Chauvet <kwizart at gmail.com>
(cherry picked from commit 779170a4faeac176fd9c578fb288fe9a726e44ed)
Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>
- - - - -
b84a9b25 by Steve Lhomme at 2026-07-25T11:39:16+00:00
NEWS: mention the switch the vpl
- - - - -
11 changed files:
- NEWS
- configure.ac
- − contrib/src/mfx/0001-detect-winstore-builds-with-a-regular-mingw32-toolch.patch
- − contrib/src/mfx/0002-Fix-linking-statically-with-intel_gfx_api-x86.dll.patch
- − contrib/src/mfx/0003-Don-t-change-the-calling-convention-of-x86-gfx-api.patch
- − contrib/src/mfx/rules.mak
- + contrib/src/vpl/0001-CMake-depend-on-libc-when-compiling-with-Clang.patch
- + contrib/src/vpl/SHA512SUMS
- + contrib/src/vpl/rules.mak
- modules/codec/Makefile.am
- modules/codec/qsv.c
Changes:
=====================================
NEWS
=====================================
@@ -107,6 +107,7 @@ Contrib:
* Update zlib to 1.3.2
* Add librist 0.2.16
* Update zvbi to 0.2.44
+ * Switch mfx Library to Intel's vpl 2.13.0
Changes between 3.0.22 and 3.0.23:
----------------------------------
=====================================
configure.ac
=====================================
@@ -3071,9 +3071,9 @@ fi
dnl
-dnl Intel QuickSync (aka MediaSDK) H264/H262 encoder
+dnl Intel Video Processing Library
dnl
-PKG_ENABLE_MODULES_VLC([MFX], [qsv], [libmfx], [Intel QuickSync MPEG4-Part10/MPEG2 (aka H.264/H.262) encoder], [auto])
+PKG_ENABLE_MODULES_VLC([VPL], [qsv], [vpl], [Intel Video Processing Library encoder], [auto])
dnl
dnl libfluidsynth (MIDI synthetizer) plugin
=====================================
contrib/src/mfx/0001-detect-winstore-builds-with-a-regular-mingw32-toolch.patch deleted
=====================================
@@ -1,40 +0,0 @@
-From c51a54c15f51579804030c70592c0a26065f1242 Mon Sep 17 00:00:00 2001
-From: Steve Lhomme <robux4 at ycbcr.xyz>
-Date: Thu, 28 May 2020 13:26:18 +0200
-Subject: [PATCH] detect winstore builds with a regular mingw32 toolchain
-
-It's trigerred with a mingw32winrt or mingw32uwp toolchain.
-
-Forcing the WINAPI_FAMILY should be enough to trigger the winstore mode.
----
- configure.ac | 14 ++++++++++++++
- 1 file changed, 14 insertions(+)
-
-diff --git a/configure.ac b/configure.ac
-index 490432a..c6f07cb 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -35,6 +35,20 @@ AS_CASE([${host_os}],
- AM_CONDITIONAL([WINDOWS_STORE], [true])
- DLLIB="$(DLLIB) -ldxgi"
- ],
-+ [mingw32], [
-+ AC_PREPROC_IFELSE([AC_LANG_PROGRAM(
-+ [[#include <winapifamily.h>
-+ #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP)
-+ # error Win32 Desktop build
-+ #endif
-+ ]],[[;]])
-+ ],[
-+ AM_CONDITIONAL([WINDOWS_STORE], [true])
-+ DLLIB="$(DLLIB) -ldxgi"
-+ ],[
-+ AM_CONDITIONAL([WINDOWS_STORE], [false])
-+ ])
-+ ],
- [
- AM_CONDITIONAL([WINDOWS_STORE], [false])
- ]
---
-2.26.0.windows.1
-
=====================================
contrib/src/mfx/0002-Fix-linking-statically-with-intel_gfx_api-x86.dll.patch deleted
=====================================
@@ -1,39 +0,0 @@
-From d16955c72e423954145fed985ad1fbda0e5ca977 Mon Sep 17 00:00:00 2001
-From: Johannes Kauffmann <19662702+JohannesKauffmann at users.noreply.github.com>
-Date: Fri, 15 Oct 2021 21:53:51 +0200
-Subject: [PATCH 2/3] Fix linking statically with intel_gfx_api-x86.dll
-
----
- src/intel_api_factory.h | 4 ++--
- src/intel_gfx_api-x86.def | 4 ++--
- 2 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/intel_api_factory.h b/src/intel_api_factory.h
-index 0be5dcb..29e9773 100644
---- a/src/intel_api_factory.h
-+++ b/src/intel_api_factory.h
-@@ -25,8 +25,8 @@ extern "C"
- {
- #endif /* __cplusplus */
-
--HRESULT APIENTRY InitialiseMediaSession(_Out_ HANDLE* handle, _In_ LPVOID lpParam, _Reserved_ LPVOID lpReserved);
--HRESULT APIENTRY DisposeMediaSession(_In_ const HANDLE handle);
-+HRESULT InitialiseMediaSession(_Out_ HANDLE* handle, _In_ LPVOID lpParam, _Reserved_ LPVOID lpReserved);
-+HRESULT DisposeMediaSession(_In_ const HANDLE handle);
-
- #ifdef __cplusplus
- }
-diff --git a/src/intel_gfx_api-x86.def b/src/intel_gfx_api-x86.def
-index 19d0727..c9c15e6 100644
---- a/src/intel_gfx_api-x86.def
-+++ b/src/intel_gfx_api-x86.def
-@@ -1,4 +1,4 @@
- LIBRARY intel_gfx_api-x86.dll
- EXPORTS
--InitialiseMediaSession at 12
--DisposeMediaSession at 4
-+InitialiseMediaSession
-+DisposeMediaSession
---
-2.27.0.windows.1
-
=====================================
contrib/src/mfx/0003-Don-t-change-the-calling-convention-of-x86-gfx-api.patch deleted
=====================================
@@ -1,35 +0,0 @@
-From 0d15135fe441acfdbbb840abea53cf696cd21470 Mon Sep 17 00:00:00 2001
-From: Johannes Kauffmann <19662702+JohannesKauffmann at users.noreply.github.com>
-Date: Tue, 19 Oct 2021 21:03:39 +0200
-Subject: [PATCH 3/3] Don't change the calling convention of x86 gfx api
-
-Upstream MediaSDK, since ae85eb2, uses __cdecl, which corresponds to
-WINAPIV in mingw64 and MSDK. The removal of APIENTRY (since f45c0c2)
-changes the calling convention from __stdcall.
-
-The removal of the '@' name decorations (also gone since f45c0c2)
-remains.
-
-Co-authored-by: Steve Lhomme <robux4 at ycbcr.xyz>
----
- src/intel_api_factory.h | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/intel_api_factory.h b/src/intel_api_factory.h
-index 29e9773..44ee7eb 100644
---- a/src/intel_api_factory.h
-+++ b/src/intel_api_factory.h
-@@ -25,8 +25,8 @@ extern "C"
- {
- #endif /* __cplusplus */
-
--HRESULT InitialiseMediaSession(_Out_ HANDLE* handle, _In_ LPVOID lpParam, _Reserved_ LPVOID lpReserved);
--HRESULT DisposeMediaSession(_In_ const HANDLE handle);
-+HRESULT WINAPIV InitialiseMediaSession(_Out_ HANDLE* handle, _In_ LPVOID lpParam, _Reserved_ LPVOID lpReserved);
-+HRESULT WINAPIV DisposeMediaSession(_In_ const HANDLE handle);
-
- #ifdef __cplusplus
- }
---
-2.27.0.windows.1
-
=====================================
contrib/src/mfx/rules.mak deleted
=====================================
@@ -1,41 +0,0 @@
-# mfx (Media SDK)
-
-mfx_GITURL := $(GITHUB)/lu-zero/mfx_dispatch.git
-MFX_GITHASH := 7efc7505465bc1f16fbd1da3d24aa5bd9d46c5ca
-
-ifeq ($(call need_pkg,"mfx"),)
-PKGS_FOUND += mfx
-endif
-ifdef HAVE_WIN32
-ifeq ($(filter arm aarch64, $(ARCH)),)
-PKGS += mfx
-endif
-endif
-
-ifdef HAVE_WINSTORE
-MFX_CONF := CFLAGS="$(CFLAGS) -DMEDIASDK_UWP_LOADER -DMEDIASDK_UWP_PROCTABLE"
-MFX_CONF += CXXFLAGS="$(CXXFLAGS) -DMEDIASDK_UWP_LOADER -DMEDIASDK_UWP_PROCTABLE"
-endif
-
-$(TARBALLS)/mfx-$(MFX_GITHASH).tar.xz:
- $(call download_git,$(mfx_GITURL),,$(MFX_GITHASH))
-
-.sum-mfx: mfx-$(MFX_GITHASH).tar.xz
- $(call check_githash,$(MFX_GITHASH))
- touch $@
-
-mfx: mfx-$(MFX_GITHASH).tar.xz .sum-mfx
- $(UNPACK)
- $(UPDATE_AUTOCONFIG)
- $(APPLY) $(SRC)/mfx/0001-detect-winstore-builds-with-a-regular-mingw32-toolch.patch
- $(APPLY) $(SRC)/mfx/0002-Fix-linking-statically-with-intel_gfx_api-x86.dll.patch
- $(APPLY) $(SRC)/mfx/0003-Don-t-change-the-calling-convention-of-x86-gfx-api.patch
- cd $(UNPACK_DIR) && autoreconf -ivf
- $(MOVE)
-
-.mfx: mfx
- $(MAKEBUILDDIR)
- $(MAKECONFIGURE) $(MFX_CONF)
- +$(MAKEBUILD)
- +$(MAKEBUILD) install
- touch $@
=====================================
contrib/src/vpl/0001-CMake-depend-on-libc-when-compiling-with-Clang.patch
=====================================
@@ -0,0 +1,28 @@
+From bb93515761bc6c4a48ff5a9361bc84c36101c3d2 Mon Sep 17 00:00:00 2001
+From: Steve Lhomme <robux4 at ycbcr.xyz>
+Date: Fri, 10 Jan 2025 08:10:21 +0100
+Subject: [PATCH] CMake: depend on libc++ when compiling with Clang
+
+libstdc++ is a GCC thing.
+---
+ libvpl/CMakeLists.txt | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/libvpl/CMakeLists.txt b/libvpl/CMakeLists.txt
+index 46503e1..fadd1cc 100644
+--- a/libvpl/CMakeLists.txt
++++ b/libvpl/CMakeLists.txt
+@@ -190,7 +190,9 @@ if(INSTALL_DEV)
+ # WIN32 in general
+ set(MINGW_LIBS "-lole32 -lgdi32 -luuid")
+ endif()
+- if(NOT MSVC)
++ if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
++ set(CXX_LIB "-lc++")
++ elseif (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
+ set(CXX_LIB "-lstdc++")
+ endif()
+ set(VPL_PKGCONFIG_DEPENDENT_LIBS
+--
+2.43.0
+
=====================================
contrib/src/vpl/SHA512SUMS
=====================================
@@ -0,0 +1 @@
+22b9f409a9b8ed551847e1b5a94d0c48502b5fbf68ec28021ba36d3f851ef83896205977e6b7f52c102f747a8fbc793424181ecd7edaf6058a39dc15b78d19cd libvpl-2.13.0.tar.gz
=====================================
contrib/src/vpl/rules.mak
=====================================
@@ -0,0 +1,47 @@
+# vpl (Intel Video Processing Library)
+
+VPL_VERSION := 2.13.0
+VPL_URL := $(GITHUB)/intel/libvpl/archive/v${VPL_VERSION}/libvpl-${VPL_VERSION}.tar.gz
+
+ifeq ($(call need_pkg,"vpl"),)
+PKGS_FOUND += vpl
+endif
+ifdef HAVE_WIN32
+ifndef HAVE_WINSTORE
+ifeq ($(filter arm aarch64, $(ARCH)),)
+PKGS += vpl
+endif
+endif
+endif
+
+DEPS_vpl :=
+
+ifdef HAVE_WINSTORE
+DEPS_vpl += alloweduwp $(DEPS_alloweduwp)
+endif
+
+ifdef HAVE_WINSTORE
+VPL_VARS := CFLAGS="$(CFLAGS) -DMEDIASDK_UWP_DISPATCHER"
+VPL_VARS += CXXFLAGS="$(CXXFLAGS) -DMEDIASDK_UWP_DISPATCHER"
+endif
+
+# Disable BUILD_EXPERIMENTAL
+# https://github.com/intel/libvpl/issues/168
+VPL_CONF := -DBUILD_EXPERIMENTAL=OFF
+
+$(TARBALLS)/libvpl-$(VPL_VERSION).tar.gz:
+ $(call download_pkg,$(VPL_URL),vpl)
+
+.sum-vpl: libvpl-$(VPL_VERSION).tar.gz
+
+vpl: libvpl-$(VPL_VERSION).tar.gz .sum-vpl
+ $(UNPACK)
+ $(APPLY) $(SRC)/vpl/0001-CMake-depend-on-libc-when-compiling-with-Clang.patch
+ $(MOVE)
+
+.vpl: vpl toolchain.cmake
+ $(CMAKECLEAN)
+ $(HOSTVARS_CMAKE) $(VPL_VARS) $(CMAKE) $(VPL_CONF)
+ +$(CMAKEBUILD)
+ $(CMAKEINSTALL)
+ touch $@
=====================================
modules/codec/Makefile.am
=====================================
@@ -618,9 +618,9 @@ EXTRA_LTLIBRARIES += libcrystalhd_plugin.la
codec_LTLIBRARIES += $(LTLIBcrystalhd)
libqsv_plugin_la_SOURCES = codec/qsv.c
-libqsv_plugin_la_CFLAGS = $(AM_CFLAGS) $(MFX_CFLAGS)
+libqsv_plugin_la_CFLAGS = $(AM_CFLAGS) $(VPL_CFLAGS)
libqsv_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(codecdir)'
-libqsv_plugin_la_LIBADD = $(MFX_LIBS)
+libqsv_plugin_la_LIBADD = $(VPL_LIBS)
EXTRA_LTLIBRARIES += libqsv_plugin.la
codec_LTLIBRARIES += $(LTLIBqsv)
=====================================
modules/codec/qsv.c
=====================================
@@ -33,7 +33,7 @@
#include <vlc_picture.h>
#include <vlc_codec.h>
-#include <mfx/mfxvideo.h>
+#include <vpl/mfxvideo.h>
#define SOUT_CFG_PREFIX "sout-qsv-"
@@ -499,7 +499,8 @@ static int Open(vlc_object_t *this)
}
char *psz_rc = var_InheritString(enc, SOUT_CFG_PREFIX "rc-method");
- msg_Dbg(enc, "Encoder using '%s' Rate Control method", psz_rc );
+ msg_Dbg(enc, "Encoder using '%s' Rate Control method",
+ psz_rc ? psz_rc : rc_method_text[0]);
sys->params.mfx.RateControlMethod = qsv_params_get_value(rc_method_text,
rc_method_list, sizeof(rc_method_list), psz_rc );
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/85d88e42e03fede23c5ec0b867208dba541bf48b...b84a9b255b706d5faa1f495d84630cb436bd09a9
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/85d88e42e03fede23c5ec0b867208dba541bf48b...b84a9b255b706d5faa1f495d84630cb436bd09a9
You're receiving this email because of your account on code.videolan.org. Manage all notifications: https://code.videolan.org/-/profile/notifications | Help: https://code.videolan.org/help
More information about the vlc-commits
mailing list