Here is an update to VLC 3.0.23.

Changes between 3.0.22 and 3.0.23:
----------------------------------

Codecs:
 * Fix WebVTT line positioning
 * Expose additional audio codec information (notably for Flac 24bit)

Demuxers:
 * fix some JPEG files wih JFIF headers

Security:
 * Fix null deref in libass, undefined shift in theora and cc-708, integer 
overflow in daala,
   Infinite loop in h264 parsing, buffer overflow in png and multiple 
format-overflows

Misc:
 * Prepare compatibility for taglib 2.0, Qt6, FFmpeg8, mingw-w64 v13 and newer 
versions of
   libplacebo and pupnp


Changes between 3.0.21 and 3.0.22:
----------------------------------

Core:
 * Assume subpictures are in SDR by default

Decoders:
 * Fix Opus channel mapping
 * Fix hardware decoding with VideoToolbox of XVID MPEG-4 video
 * Add dav1d-all-layers option
 * Fix DVD CEA-608 captions parsing
 * Fix ProRes 4:4:4:4
 * Disable decoding using libdca, libmpeg2 and liba52 by default in favor of 
libavcodec

Demuxers:
 * Add support for DMX audio music (MUS) files
 * Handle mkv-use-chapter-codec option
 * Add A_ATRAC/AT1 support in matroska
 * Prevent FLAC seeking logic get stuck
 * Handle pictures in FLAC
 * Fix VOB/AOB LPCM/MLP detection failing occasionally
 * Cut QNap title on first invalid character
 * Fix display of certain JPEG files
 * Fix playback of very short ASF files (duration less than 1s)
 * Multiple fixes in MPEG-TS
 * Fix crashes in multiple demuxers (reported by rub.de, oss-fuzz and others)

Input:
 * Fix SFTP seeking for large files on 32-bit OS

Interface:
 * Qt: Add option to use dark palette
 * Qt: Add compilation support for newer versions of Qt5
 * Qt: Fix scrolling on volume slider
 * macOS: fix crashes when drag'n drop items in the playlist
 * KDE: fix MPRIS state when started from file

Service Discovery:
 * UPnP: remove SAT>IP channel list fallback

Video Output:
 * Use a better stretch mode in wingdi
 * Fetch missing device information when running in UWP

Video Filter:
 * Add AMD GPU Frame Rate Doubler (Direct3D11)
 * Improve visualization of low frequencies in spectrogram

Misc:
 * gnutls: remove manual DH prime bits setting
 * Avoid very large fonts in portrait mode
 * Update of most translations

Security:
 * Heap Buffer Overflow READ in TY, NSV, CVDsub, SPU, Subrip, TX3G, MPJEG 
demuxers and decoders
 * Heap Buffer Overflow Write in RLE, MP4, TX3G demuxers and decoders
 * Assert failure in AVI, MP4 demuxers and Core
 * Null dereferences in CSS, Flac and VTT modules
 * Use-after Free in SVG decoder
 * Crash in Subtitles core, in jpeg2 inside TS
 * Multiple crashes and OOB in CEA-708 subtitles
 * OOB read on Oggspot, MP4
 * Multiple leaks in MKV, ASF/WMV, CAF and PS demuxers, Ogg, Theora, Vorbis,
   WebVTT and SVCD decoders
 * Busy loop in WebVTT
  (The list above is not exhaustive)


Index: Makefile
===================================================================
RCS file: /cvs/ports/x11/vlc/Makefile,v
retrieving revision 1.289
diff -u -p -u -p -r1.289 Makefile
--- Makefile    1 Nov 2025 11:16:43 -0000       1.289
+++ Makefile    9 Jan 2026 04:06:55 -0000
@@ -1,15 +1,13 @@
 COMMENT-main=  VideoLAN client; multimedia player
 COMMENT-jack=  JACK audio output module for VLC
 
-V=             3.0.21
+V=             3.0.23
 DISTNAME=      vlc-${V}
 PKGNAME-main=  ${DISTNAME}
 PKGNAME-jack=  vlc-jack-${V}
 CATEGORIES=    x11
 SITES=         https://download.videolan.org/pub/videolan/vlc/${V}/
 EXTRACT_SUFX=  .tar.xz
-REVISION-jack= 1
-REVISION-main= 10
 
 USE_NOBTCFI=   Yes
 
@@ -68,10 +66,10 @@ WANTLIB-main += gio-2.0 glapi glib-2.0 g
 WANTLIB-main += gpg-error graphite2 gsm gthread-2.0 gtk-3 harfbuzz
 WANTLIB-main += hogweed icudata icui18n icuuc idn2 jpeg lz4 lzma matroska
 WANTLIB-main += mp3lame nettle nfs notify ogg opus p11-kit pango-1.0
-WANTLIB-main += pangocairo-1.0 pangoft2-1.0 pciaccess pcre2-16 pcre2-8
+WANTLIB-main += pangocairo-1.0 pangoft2-1.0 pcre2-16 pcre2-8
 WANTLIB-main += pixman-1 png protobuf-lite rsvg-2 sharpyuv
 WANTLIB-main += smb2 sndio soxr speex speexdsp ssl swresample swscale
-WANTLIB-main += tag tar tasn1 theoradec theoraenc tiff udfread unibreak
+WANTLIB-main += tag tasn1 theoradec theoraenc tiff udfread unibreak
 WANTLIB-main += unistring usbhid utf8_range utf8_validity va va-drm
 WANTLIB-main += va-x11 vorbis vorbisenc vpx wayland-client wayland-cursor
 WANTLIB-main += wayland-egl webp webpmux x264 x265 xcb xcb-composite
@@ -88,7 +86,7 @@ WANTLIB-main+=        v4l2
 
 WANTLIB-jack=  db execinfo jack vlccore ${WANTLIB-common}
 
-AUTOCONF_VERSION= 2.71
+AUTOCONF_VERSION= 2.69
 AUTOMAKE_VERSION= 1.16
 AUTORECONF=    ./bootstrap
 
@@ -109,13 +107,12 @@ LIB_DEPENDS-main= ${MODQT5_LIB_DEPENDS} 
                x11/qt5/qtsvg,-main \
                x11/qt5/qtx11extras \
                archivers/libarchive \
-               archivers/libtar \
                audio/libcddb \
                audio/libsoxr \
                audio/libvorbis \
                audio/opus \
                audio/speex \
-               audio/taglib>=2.0.2 \
+               audio/taglib \
                devel/fribidi \
                devel/gettext,-runtime \
                devel/harfbuzz \
@@ -160,8 +157,7 @@ USE_GMAKE=  Yes
 LIBTOOL_FLAGS= --tag=disable-static
 CONFIGURE_STYLE= autoreconf
 MODGNU_CONFIG_GUESS_DIRS= ${WRKSRC}/autotools
-CONFIGURE_ARGS+=--disable-a52 \
-               --disable-alsa \
+CONFIGURE_ARGS+=--disable-alsa \
                --disable-altivec \
                --disable-aom \
                --disable-aribb25 \
@@ -172,7 +168,6 @@ CONFIGURE_ARGS+=--disable-a52 \
                --disable-crystalhd \
                --disable-dav1d \
                --disable-dc1394 \
-               --disable-dca \
                --disable-decklink \
                --disable-dsm \
                --disable-dv1394 \
@@ -186,9 +181,7 @@ CONFIGURE_ARGS+=--disable-a52 \
                --disable-gst-decode \
                --disable-kate \
                --disable-kwallet \
-               --disable-libmpeg2 \
                --disable-libplacebo \
-               --disable-libva \
                --disable-linsys \
                --disable-live555 \
                --disable-mad \
Index: distinfo
===================================================================
RCS file: /cvs/ports/x11/vlc/distinfo,v
retrieving revision 1.49
diff -u -p -u -p -r1.49 distinfo
--- distinfo    16 Nov 2024 09:26:57 -0000      1.49
+++ distinfo    9 Jan 2026 04:06:55 -0000
@@ -1,2 +1,2 @@
-SHA256 (vlc-3.0.21.tar.xz) = JNu+HX367qCZTV3vC73iABdzRxNtv+Vz9bakzuJa+7A=
-SIZE (vlc-3.0.21.tar.xz) = 25649288
+SHA256 (vlc-3.0.23.tar.xz) = 6JHK5qo8zaab+UFz1RBcvFXHp9mx0hubIWZuae/z5+A=
+SIZE (vlc-3.0.23.tar.xz) = 26486988
Index: patches/patch-compat_Makefile_am
===================================================================
RCS file: /cvs/ports/x11/vlc/patches/patch-compat_Makefile_am,v
retrieving revision 1.4
diff -u -p -u -p -r1.4 patch-compat_Makefile_am
--- patches/patch-compat_Makefile_am    11 Mar 2022 20:17:31 -0000      1.4
+++ patches/patch-compat_Makefile_am    9 Jan 2026 04:06:55 -0000
@@ -4,7 +4,8 @@ plugins is not portable.
 Index: compat/Makefile.am
 --- compat/Makefile.am.orig
 +++ compat/Makefile.am
-@@ -1,7 +1,7 @@
+@@ -1,8 +1,8 @@
+ noinst_HEADERS = stdckdint/stdckdint.h
 -pkglib_LTLIBRARIES = libcompat.la
 +noinst_LTLIBRARIES = libcompat.la
  libcompat_la_SOURCES = dummy.c
Index: patches/patch-configure_ac
===================================================================
RCS file: /cvs/ports/x11/vlc/patches/patch-configure_ac,v
retrieving revision 1.46
diff -u -p -u -p -r1.46 patch-configure_ac
--- patches/patch-configure_ac  19 Mar 2025 11:13:38 -0000      1.46
+++ patches/patch-configure_ac  9 Jan 2026 04:06:55 -0000
@@ -1,7 +1,3 @@
-- libass: fix fontconfig detection
-  d19599c42141eaf72cae9a0cb21b5889cd01c860
-- configure: look for backtrace() in libexecinfo
-  b3179e1e0993b8c15b735c93282c7675632c183c
 
 Index: configure.ac
 --- configure.ac.orig
@@ -16,7 +12,7 @@ Index: configure.ac
      ;;
    netbsd*)
      SYS=netbsd
-@@ -1122,22 +1121,6 @@ AC_ARG_ENABLE(optimizations,
+@@ -1170,22 +1169,6 @@ AC_ARG_ENABLE(optimizations,
  dnl Check for various optimization flags
  AS_IF([test "${enable_optimizations}" != "no"], [
  
@@ -39,24 +35,7 @@ Index: configure.ac
    dnl Check for fast maths
    AX_APPEND_COMPILE_FLAGS([-fno-math-errno -funsafe-math-optimizations 
-fno-rounding-math -fno-signaling-nans -fcx-limited-range], [CFLAGS])
    AX_APPEND_COMPILE_FLAGS([-fno-math-errno -funsafe-math-optimizations 
-fno-rounding-math -fno-signaling-nans -fcx-limited-range], [CXXFLAGS])
-@@ -1246,9 +1229,14 @@ case "${host_cpu}" in
- esac
- 
- dnl Check for backtrace() support
--AC_CHECK_HEADERS(execinfo.h)
--AC_CHECK_FUNCS(backtrace)
-+AC_CHECK_HEADERS([execinfo.h])
-+AC_CHECK_FUNCS([backtrace],, [
-+  AC_CHECK_LIB([execinfo], [backtrace], [
-+    LIBEXECINFO="-lexecinfo"])
-+])
-+AC_SUBST(LIBEXECINFO)
- 
-+
- dnl
- dnl  default modules
- dnl
-@@ -1668,7 +1656,7 @@ AC_ARG_ENABLE(lua,
+@@ -1758,7 +1741,7 @@ AC_ARG_ENABLE(lua,
      [disable LUA scripting support (default enabled)])])
  if test "${enable_lua}" != "no"
  then
@@ -65,55 +44,3 @@ Index: configure.ac
      [ have_lua=yes ],
      [
      AC_MSG_WARN([${LUA_PKG_ERRORS}, trying lua 5.1 instead])
-@@ -2989,25 +2977,6 @@ AS_IF( [test "${enable_telx}" != "no" ],[
-   ])
- 
- dnl
--dnl libass subtitle rendering module
--dnl
--AC_ARG_ENABLE(libass,
--  [  --enable-libass         Subtitle support using libass (default enabled)])
--AS_IF( [test "${enable_libass}" != "no"], [
--  PKG_CHECK_MODULES(LIBASS, [libass >= 0.9.8],
--      [
--        VLC_ADD_PLUGIN([libass])
--
--        AC_CHECK_HEADERS(fontconfig/fontconfig.h,
--          [VLC_ADD_CPPFLAGS([libass],[-DHAVE_FONTCONFIG])
--           VLC_ADD_LIBS([libass],[-lfontconfig])
--       ])
--      ],[
--        AC_MSG_WARN([${LIBASS_PKG_ERRORS}.])
--      ])
--  ])
--
--dnl
- dnl ARIB subtitles rendering module
- dnl
- AC_ARG_ENABLE(aribsub,
-@@ -3346,6 +3315,25 @@ AM_CONDITIONAL([HAVE_FREETYPE], [test "${have_freetype
- AM_CONDITIONAL([HAVE_FONTCONFIG], [test "${have_fontconfig}" = "yes"])
- AM_CONDITIONAL([HAVE_FRIBIDI], [test "${have_fribidi}" = "yes"])
- AM_CONDITIONAL([HAVE_HARFBUZZ], [test "${have_harfbuzz}" = "yes"])
-+
-+dnl
-+dnl libass subtitle rendering module
-+dnl
-+AC_ARG_ENABLE(libass,
-+  [  --enable-libass         Subtitle support using libass (default enabled)])
-+AS_IF( [test "${enable_libass}" != "no"], [
-+  PKG_CHECK_MODULES(LIBASS, [libass >= 0.9.8],
-+      [
-+        VLC_ADD_PLUGIN([libass])
-+
-+        if test "${have_fontconfig}" != "no"; then
-+            VLC_ADD_CPPFLAGS([libass],[-DHAVE_FONTCONFIG])
-+            VLC_ADD_LIBS([libass],[${FONTCONFIG_LIBS}])
-+        fi
-+      ],[
-+        AC_MSG_WARN([${LIBASS_PKG_ERRORS}.])
-+      ])
-+  ])
- 
- dnl
- dnl SAPI (text to Speech renderer for Windows)
Index: patches/patch-modules_access_nfs_c
===================================================================
RCS file: patches/patch-modules_access_nfs_c
diff -N patches/patch-modules_access_nfs_c
--- patches/patch-modules_access_nfs_c  16 Jul 2025 09:42:36 -0000      1.1
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,32 +0,0 @@
-- nfs: fix libnfs API v2 support
-  41f1c168a5a9c5ac5c88ecbbe0f8f4ddef8b999f
-
-Index: modules/access/nfs.c
---- modules/access/nfs.c.orig
-+++ modules/access/nfs.c
-@@ -189,7 +189,8 @@ nfs_read_cb(int i_status, struct nfs_context *p_nfs, v
-     else
-     {
-         p_sys->res.read.i_len = i_status;
--        memcpy(p_sys->res.read.p_buf, p_data, i_status);
-+        if (p_sys->res.read.p_buf != NULL && p_data != NULL)
-+            memcpy(p_sys->res.read.p_buf, p_data, i_status);
-     }
- }
- 
-@@ -209,9 +210,15 @@ FileRead(stream_t *p_access, void *p_buf, size_t i_len
-         return 0;
- 
-     p_sys->res.read.i_len = 0;
-+#ifdef LIBNFS_API_V2
-+    p_sys->res.read.p_buf = NULL;
-+    if (nfs_read_async(p_sys->p_nfs, p_sys->p_nfsfh, p_buf, i_len, 
nfs_read_cb,
-+                       p_access) < 0)
-+#else
-     p_sys->res.read.p_buf = p_buf;
-     if (nfs_read_async(p_sys->p_nfs, p_sys->p_nfsfh, i_len, nfs_read_cb,
-                        p_access) < 0)
-+#endif
-     {
-         msg_Err(p_access, "nfs_read_async failed");
-         return 0;
Index: patches/patch-modules_codec_avcodec_audio_c
===================================================================
RCS file: patches/patch-modules_codec_avcodec_audio_c
diff -N patches/patch-modules_codec_avcodec_audio_c
--- patches/patch-modules_codec_avcodec_audio_c 21 Oct 2025 13:08:08 -0000      
1.10
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,154 +0,0 @@
-https://code.videolan.org/videolan/vlc/-/merge_requests/2814
-https://code.videolan.org/videolan/vlc/-/merge_requests/3872
-
-Index: modules/codec/avcodec/audio.c
---- modules/codec/avcodec/audio.c.orig
-+++ modules/codec/avcodec/audio.c
-@@ -139,7 +139,11 @@ static int OpenAudioCodec( decoder_t *p_dec )
-     }
- 
-     ctx->sample_rate = p_dec->fmt_in.audio.i_rate;
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(59, 24, 100))
-+    av_channel_layout_default( &ctx->ch_layout, 
p_dec->fmt_in.audio.i_channels );
-+#else
-     ctx->channels = p_dec->fmt_in.audio.i_channels;
-+#endif
-     ctx->block_align = p_dec->fmt_in.audio.i_blockalign;
-     ctx->bit_rate = p_dec->fmt_in.i_bitrate;
-     ctx->bits_per_coded_sample = p_dec->fmt_in.audio.i_bitspersample;
-@@ -261,12 +265,6 @@ int InitAudioDec( vlc_object_t *obj )
-     p_dec->pf_decode = DecodeAudio;
-     p_dec->pf_flush  = Flush;
- 
--    /* XXX: Writing input format makes little sense. */
--    if( avctx->profile != FF_PROFILE_UNKNOWN )
--        p_dec->fmt_in.i_profile = avctx->profile;
--    if( avctx->level != FF_LEVEL_UNKNOWN )
--        p_dec->fmt_in.i_level = avctx->level;
--
-     return VLC_SUCCESS;
- }
- 
-@@ -395,12 +393,17 @@ static int DecodeBlock( decoder_t *p_dec, block_t **pp
-         ret = avcodec_receive_frame( ctx, frame );
-         if( ret == 0 )
-         {
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(59, 24, 100))
-+            int channels = frame->ch_layout.nb_channels;
-+#else
-+            int channels = ctx->channels;
-+#endif
-             /* checks and init from first decoded frame */
--            if( ctx->channels <= 0 || ctx->channels > INPUT_CHAN_MAX
-+            if( channels <= 0 || channels > INPUT_CHAN_MAX
-              || ctx->sample_rate <= 0 )
-             {
-                 msg_Warn( p_dec, "invalid audio properties channels count %d, 
sample rate %d",
--                          ctx->channels, ctx->sample_rate );
-+                          channels, ctx->sample_rate );
-                 goto drop;
-             }
-             else if( p_dec->fmt_out.audio.i_rate != (unsigned 
int)ctx->sample_rate )
-@@ -484,15 +487,15 @@ static block_t * ConvertAVFrame( decoder_t *p_dec, AVF
-     /* Interleave audio if required */
-     if( av_sample_fmt_is_planar( ctx->sample_fmt ) )
-     {
--        p_block = block_Alloc(frame->linesize[0] * ctx->channels);
-+        p_block = block_Alloc(frame->linesize[0] * 
p_dec->fmt_out.audio.i_channels );
-         if ( likely(p_block) )
-         {
--            const void *planes[ctx->channels];
--            for (int i = 0; i < ctx->channels; i++)
-+            const void *planes[p_dec->fmt_out.audio.i_channels];
-+            for (int i = 0; i < p_dec->fmt_out.audio.i_channels; i++)
-                 planes[i] = frame->extended_data[i];
- 
-             aout_Interleave(p_block->p_buffer, planes, frame->nb_samples,
--                            ctx->channels, p_dec->fmt_out.audio.i_format);
-+                            p_dec->fmt_out.audio.i_channels, 
p_dec->fmt_out.audio.i_format);
-             p_block->i_nb_samples = frame->nb_samples;
-         }
-         av_frame_free(&frame);
-@@ -511,7 +514,7 @@ static block_t * ConvertAVFrame( decoder_t *p_dec, AVF
-         {
-             aout_ChannelExtract( p_buffer->p_buffer,
-                                  p_dec->fmt_out.audio.i_channels,
--                                 p_block->p_buffer, ctx->channels,
-+                                 p_block->p_buffer, 
p_dec->fmt_out.audio.i_channels,
-                                  p_block->i_nb_samples, p_sys->pi_extraction,
-                                  p_dec->fmt_out.audio.i_bitspersample );
-             p_buffer->i_nb_samples = p_block->i_nb_samples;
-@@ -568,6 +571,7 @@ static const uint64_t pi_channels_map[][2] =
-     { AV_CH_TOP_BACK_RIGHT,    0 },
-     { AV_CH_STEREO_LEFT,       0 },
-     { AV_CH_STEREO_RIGHT,      0 },
-+    { 0, 0 },
- };
- 
- static void SetupOutputFormat( decoder_t *p_dec, bool b_trust )
-@@ -580,6 +584,16 @@ static void SetupOutputFormat( decoder_t *p_dec, bool 
-     p_dec->fmt_out.audio.i_rate = p_sys->p_context->sample_rate;
- 
-     /* */
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(59, 24, 100))
-+    if( p_sys->i_previous_channels == p_sys->p_context->ch_layout.nb_channels 
&&
-+        p_sys->i_previous_layout == p_sys->p_context->ch_layout.u.mask )
-+        return;
-+    if( b_trust )
-+    {
-+        p_sys->i_previous_channels = p_sys->p_context->ch_layout.nb_channels;
-+        p_sys->i_previous_layout = p_sys->p_context->ch_layout.u.mask;
-+    }
-+#else
-     if( p_sys->i_previous_channels == p_sys->p_context->channels &&
-         p_sys->i_previous_layout == p_sys->p_context->channel_layout )
-         return;
-@@ -588,25 +602,31 @@ static void SetupOutputFormat( decoder_t *p_dec, bool 
-         p_sys->i_previous_channels = p_sys->p_context->channels;
-         p_sys->i_previous_layout = p_sys->p_context->channel_layout;
-     }
-+#endif
- 
--    const unsigned i_order_max = 
sizeof(pi_channels_map)/sizeof(*pi_channels_map);
--    uint32_t pi_order_src[i_order_max];
-+    uint32_t pi_order_src[AOUT_CHAN_MAX] = { 0 };
- 
-     int i_channels_src = 0;
--    int64_t channel_layout =
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(59, 24, 100))
-+    uint64_t channel_layout_mask = p_sys->p_context->ch_layout.u.mask;
-+    int channel_count = p_sys->p_context->ch_layout.nb_channels;
-+#else
-+    uint64_t channel_layout_mask =
-         p_sys->p_context->channel_layout ? p_sys->p_context->channel_layout :
-         av_get_default_channel_layout( p_sys->p_context->channels );
-+    int channel_count = p_sys->p_context->channels;
-+#endif
- 
--    if( channel_layout )
-+    if( channel_layout_mask )
-     {
--        for( unsigned i = 0; i < i_order_max
--         && i_channels_src < p_sys->p_context->channels; i++ )
-+        for( unsigned i = 0; pi_channels_map[i][0]
-+         && i_channels_src < channel_count; i++ )
-         {
--            if( channel_layout & pi_channels_map[i][0] )
-+            if( channel_layout_mask & pi_channels_map[i][0] )
-                 pi_order_src[i_channels_src++] = pi_channels_map[i][1];
-         }
- 
--        if( i_channels_src != p_sys->p_context->channels && b_trust )
-+        if( i_channels_src != channel_count && b_trust )
-             msg_Err( p_dec, "Channel layout not understood" );
- 
-         /* Detect special dual mono case */
-@@ -638,7 +658,7 @@ static void SetupOutputFormat( decoder_t *p_dec, bool 
-     {
-         msg_Warn( p_dec, "no channel layout found");
-         p_dec->fmt_out.audio.i_physical_channels = 0;
--        p_dec->fmt_out.audio.i_channels = p_sys->p_context->channels;
-+        p_dec->fmt_out.audio.i_channels = channel_count;
-     }
- 
-     aout_FormatPrepare( &p_dec->fmt_out.audio );
Index: patches/patch-modules_codec_avcodec_avcommon_compat_h
===================================================================
RCS file: patches/patch-modules_codec_avcodec_avcommon_compat_h
diff -N patches/patch-modules_codec_avcodec_avcommon_compat_h
--- patches/patch-modules_codec_avcodec_avcommon_compat_h       21 Oct 2025 
13:08:08 -0000      1.3
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,18 +0,0 @@
-ffmpeg8 removes it without any replacment
-
-Index: modules/codec/avcodec/avcommon_compat.h
---- modules/codec/avcodec/avcommon_compat.h.orig
-+++ modules/codec/avcodec/avcommon_compat.h
-@@ -71,8 +71,11 @@
- #ifndef AV_CODEC_CAP_SMALL_LAST_FRAME
- # define AV_CODEC_CAP_SMALL_LAST_FRAME CODEC_CAP_SMALL_LAST_FRAME
- #endif
--#ifndef AV_INPUT_BUFFER_MIN_SIZE
-+#if !defined(AV_INPUT_BUFFER_MIN_SIZE) && defined(FF_MIN_BUFFER_SIZE)
- # define AV_INPUT_BUFFER_MIN_SIZE FF_MIN_BUFFER_SIZE
-+#endif
-+#ifndef AV_INPUT_BUFFER_MIN_SIZE
-+# define AV_INPUT_BUFFER_MIN_SIZE 16384
- #endif
- #ifndef  FF_MAX_B_FRAMES
- # define  FF_MAX_B_FRAMES 16 // FIXME: remove this
Index: patches/patch-modules_codec_avcodec_encoder_c
===================================================================
RCS file: patches/patch-modules_codec_avcodec_encoder_c
diff -N patches/patch-modules_codec_avcodec_encoder_c
--- patches/patch-modules_codec_avcodec_encoder_c       21 Oct 2025 13:08:08 
-0000      1.9
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,422 +0,0 @@
-https://code.videolan.org/videolan/vlc/-/merge_requests/6657
-https://code.videolan.org/videolan/vlc/-/merge_requests/3854
-
-Index: modules/codec/avcodec/encoder.c
---- modules/codec/avcodec/encoder.c.orig
-+++ modules/codec/avcodec/encoder.c
-@@ -181,6 +181,7 @@ static const uint64_t pi_channels_map[][2] =
-     { AV_CH_STEREO_RIGHT,      0 },
- };
- 
-+#if (LIBAVCODEC_VERSION_INT < AV_VERSION_INT( 59, 24, 100 ))
- static const uint32_t channel_mask[][2] = {
-     {0,0},
-     {AOUT_CHAN_CENTER, AV_CH_LAYOUT_MONO},
-@@ -193,6 +194,7 @@ static const uint32_t channel_mask[][2] = {
-     {AOUT_CHANS_7_1, AV_CH_LAYOUT_7POINT1},
-     {AOUT_CHANS_8_1, AV_CH_LAYOUT_OCTAGONAL},
- };
-+#endif
- 
- static const char *const ppsz_enc_options[] = {
-     "keyint", "bframes", "vt", "qmin", "qmax", "codec", "hq",
-@@ -252,19 +254,29 @@ static void probe_video_frame_rate( encoder_t *p_enc, 
-                                   ( p_enc->fmt_out.i_codec == VLC_CODEC_MP4V 
? 25 : CLOCK_FREQ );
- 
-     msg_Dbg( p_enc, "Time base for probing set to %d/%d", 
p_context->time_base.num, p_context->time_base.den );
--    if( p_codec->supported_framerates )
-+
-+    const AVRational *supported_framerates;
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 61, 13, 100 ))
-+    if (avcodec_get_supported_config(p_context, p_codec, 
AV_CODEC_CONFIG_FRAME_RATE, 0,
-+                                     (const void **)&supported_framerates, 
NULL) < 0)
-+        supported_framerates = NULL;
-+#else
-+    supported_framerates = p_codec->supported_framerates;
-+#endif
-+
-+    if( supported_framerates )
-     {
-         /* We are finding fps values so 1/time_base */
-         AVRational target = {
-             .num = p_context->time_base.den,
-             .den = p_context->time_base.num
-         };
--        int idx = av_find_nearest_q_idx(target, 
p_codec->supported_framerates);
-+        int idx = av_find_nearest_q_idx(target, supported_framerates);
- 
--        p_context->time_base.num = p_codec->supported_framerates[idx].den ?
--                                    p_codec->supported_framerates[idx].den : 
1;
--        p_context->time_base.den = p_codec->supported_framerates[idx].den ?
--                                    p_codec->supported_framerates[idx].num : 
CLOCK_FREQ;
-+        p_context->time_base.num = supported_framerates[idx].den ?
-+                                    supported_framerates[idx].den : 1;
-+        p_context->time_base.den = supported_framerates[idx].den ?
-+                                    supported_framerates[idx].num : 
CLOCK_FREQ;
- 
-         /* If we have something reasonable on supported framerates, use that*/
-         if( p_context->time_base.den && p_context->time_base.den < CLOCK_FREQ 
)
-@@ -468,30 +480,30 @@ int InitVideoEnc( vlc_object_t *p_this )
-     psz_val = var_GetString( p_enc, ENC_CFG_PREFIX "aac-profile" );
-     /* libavcodec uses faac encoder atm, and it has issues with
-      * other than low-complexity profile, so default to that */
--    p_sys->i_aac_profile = FF_PROFILE_AAC_LOW;
-+    p_sys->i_aac_profile = AV_PROFILE_AAC_LOW;
-     if( psz_val && *psz_val )
-     {
-         if( !strncmp( psz_val, "main", 4 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_MAIN;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_MAIN;
-         else if( !strncmp( psz_val, "low", 3 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_LOW;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_LOW;
-         else if( !strncmp( psz_val, "ssr", 3 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_SSR;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_SSR;
-         else if( !strncmp( psz_val, "ltp", 3 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_LTP;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_LTP;
- /* These require libavcodec with libfdk-aac */
-         else if( !strncmp( psz_val, "hev2", 4 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_HE_V2;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_HE_V2;
-         else if( !strncmp( psz_val, "hev1", 4 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_HE;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_HE;
-         else if( !strncmp( psz_val, "ld", 2 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_LD;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_LD;
-         else if( !strncmp( psz_val, "eld", 3 ) )
--            p_sys->i_aac_profile = FF_PROFILE_AAC_ELD;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_ELD;
-         else
-         {
-             msg_Warn( p_enc, "unknown AAC profile requested, setting it to 
low" );
--            p_sys->i_aac_profile = FF_PROFILE_AAC_LOW;
-+            p_sys->i_aac_profile = AV_PROFILE_AAC_LOW;
-         }
-     }
-     free( psz_val );
-@@ -553,7 +565,16 @@ int InitVideoEnc( vlc_object_t *p_this )
-         p_enc->fmt_in.video.i_chroma = p_enc->fmt_in.i_codec;
-         GetFfmpegChroma( &p_context->pix_fmt, &p_enc->fmt_in.video );
- 
--        if( p_codec->pix_fmts )
-+        const enum AVPixelFormat *pix_fmts;
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 61, 13, 100 ))
-+        if (avcodec_get_supported_config(p_context, p_codec, 
AV_CODEC_CONFIG_PIX_FORMAT, 0,
-+                                        (const void **)&pix_fmts, NULL) < 0)
-+            pix_fmts = NULL;
-+#else
-+        pix_fmts = p_codec->pix_fmts;
-+#endif
-+
-+        if( pix_fmts )
-         {
-             static const enum AVPixelFormat vlc_pix_fmts[] = {
-                 AV_PIX_FMT_YUV420P,
-@@ -561,8 +582,8 @@ int InitVideoEnc( vlc_object_t *p_this )
-                 AV_PIX_FMT_RGB24,
-             };
-             bool found = false;
--            const enum PixelFormat *p = p_codec->pix_fmts;
--            for( ; !found && *p != -1; p++ )
-+            const enum AVPixelFormat *p = pix_fmts;
-+            for( ; !found && *p != AV_PIX_FMT_NONE; p++ )
-             {
-                 for( size_t i = 0; i < ARRAY_SIZE(vlc_pix_fmts); ++i )
-                 {
-@@ -574,7 +595,7 @@ int InitVideoEnc( vlc_object_t *p_this )
-                     }
-                 }
-             }
--            if (!found) p_context->pix_fmt = p_codec->pix_fmts[0];
-+            if (!found) p_context->pix_fmt = pix_fmts[0];
-             GetVlcChroma( &p_enc->fmt_in.video, p_context->pix_fmt );
-             p_enc->fmt_in.i_codec = p_enc->fmt_in.video.i_chroma;
-         }
-@@ -699,22 +720,29 @@ int InitVideoEnc( vlc_object_t *p_this )
-     }
-     else if( p_enc->fmt_in.i_cat == AUDIO_ES )
-     {
-+        const enum AVSampleFormat *sample_fmts;
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 61, 13, 100 ))
-+        if (avcodec_get_supported_config(p_context, p_codec, 
AV_CODEC_CONFIG_SAMPLE_FORMAT, 0,
-+                                        (const void **)&sample_fmts, NULL) < 
0)
-+            sample_fmts = NULL;
-+#else
-+        sample_fmts = p_codec->sample_fmts;
-+#endif
-+
-         p_context->codec_type  = AVMEDIA_TYPE_AUDIO;
--        p_context->sample_fmt  = p_codec->sample_fmts ?
--                                    p_codec->sample_fmts[0] :
--                                    AV_SAMPLE_FMT_S16;
-+        p_context->sample_fmt  = sample_fmts ? sample_fmts[0] : 
AV_SAMPLE_FMT_S16;
- 
-         /* Try to match avcodec input format to vlc format so we could avoid 
one
-            format conversion */
-         if( GetVlcAudioFormat( p_context->sample_fmt ) != 
p_enc->fmt_in.i_codec
--            && p_codec->sample_fmts )
-+            && sample_fmts )
-         {
-             msg_Dbg( p_enc, "Trying to find more suitable sample format 
instead of %s", av_get_sample_fmt_name( p_context->sample_fmt ) );
--            for( unsigned int i=0; p_codec->sample_fmts[i] != -1; i++ )
-+            for( unsigned int i=0; sample_fmts[i] != AV_SAMPLE_FMT_NONE; i++ )
-             {
--                if( GetVlcAudioFormat( p_codec->sample_fmts[i] ) == 
p_enc->fmt_in.i_codec )
-+                if( GetVlcAudioFormat( sample_fmts[i] ) == 
p_enc->fmt_in.i_codec )
-                 {
--                    p_context->sample_fmt = p_codec->sample_fmts[i];
-+                    p_context->sample_fmt = sample_fmts[i];
-                     msg_Dbg( p_enc, "Using %s as new sample format", 
av_get_sample_fmt_name( p_context->sample_fmt ) );
-                     break;
-                 }
-@@ -723,14 +751,14 @@ int InitVideoEnc( vlc_object_t *p_this )
-         p_sys->b_planar = av_sample_fmt_is_planar( p_context->sample_fmt );
-         // Try if we can use interleaved format for codec input as VLC 
doesn't really do planar audio yet
-         // FIXME: Remove when planar/interleaved audio in vlc is equally 
supported
--        if( p_sys->b_planar && p_codec->sample_fmts )
-+        if( p_sys->b_planar && sample_fmts )
-         {
-             msg_Dbg( p_enc, "Trying to find packet sample format instead of 
planar %s", av_get_sample_fmt_name( p_context->sample_fmt ) );
--            for( unsigned int i=0; p_codec->sample_fmts[i] != -1; i++ )
-+            for( unsigned int i=0; sample_fmts[i] != AV_SAMPLE_FMT_NONE; i++ )
-             {
--                if( !av_sample_fmt_is_planar( p_codec->sample_fmts[i] ) )
-+                if( !av_sample_fmt_is_planar( sample_fmts[i] ) )
-                 {
--                    p_context->sample_fmt = p_codec->sample_fmts[i];
-+                    p_context->sample_fmt = sample_fmts[i];
-                     msg_Dbg( p_enc, "Changing to packet format %s as new 
sample format", av_get_sample_fmt_name( p_context->sample_fmt ) );
-                     break;
-                 }
-@@ -745,58 +773,43 @@ int InitVideoEnc( vlc_object_t *p_this )
-         date_Set( &p_sys->buffer_date, AV_NOPTS_VALUE );
-         p_context->time_base.num = 1;
-         p_context->time_base.den = p_context->sample_rate;
--        p_context->channels      = p_enc->fmt_out.audio.i_channels;
--#if LIBAVUTIL_VERSION_CHECK( 52, 2, 6, 0, 0)
--        p_context->channel_layout = channel_mask[p_context->channels][1];
- 
--        /* Setup Channel ordering for multichannel audio
-+        /* Setup Channel ordering for audio
-          * as VLC channel order isn't same as libavcodec expects
-          */
- 
-         p_sys->i_channels_to_reorder = 0;
- 
--        /* Specified order
-+        /* Create channel layout for avcodec
-          * Copied from audio.c
-          */
--        const unsigned i_order_max = 8 * sizeof(p_context->channel_layout);
-         uint32_t pi_order_dst[AOUT_CHAN_MAX] = { };
-         uint32_t order_mask = 0;
-         int i_channels_src = 0;
- 
--        if( p_context->channel_layout )
--        {
--            msg_Dbg( p_enc, "Creating channel order for reordering");
--            for( unsigned i = 0; i < 
sizeof(pi_channels_map)/sizeof(*pi_channels_map); i++ )
-+        msg_Dbg( p_enc, "Creating channel order for reordering");
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 24, 100 ))
-+        av_channel_layout_default( &p_context->ch_layout, 
p_enc->fmt_out.audio.i_channels );
-+        uint64_t channel_mask = p_context->ch_layout.u.mask;
-+#else
-+        p_context->channels = p_enc->fmt_out.audio.i_channels;
-+        p_context->channel_layout = channel_mask[p_context->channels][1];
-+        uint64_t channel_mask = p_context->channel_layout;
-+#endif
-+        for( unsigned i = 0; i < 
sizeof(pi_channels_map)/sizeof(*pi_channels_map); i++ )
-+            if( channel_mask & pi_channels_map[i][0] )
-             {
--                if( p_context->channel_layout & pi_channels_map[i][0] )
--                {
--                    msg_Dbg( p_enc, "%d %"PRIx64" mapped to %"PRIx64"", 
i_channels_src, pi_channels_map[i][0], pi_channels_map[i][1]);
--                    pi_order_dst[i_channels_src++] = pi_channels_map[i][1];
--                    order_mask |= pi_channels_map[i][1];
--                }
-+                msg_Dbg( p_enc, "%d %"PRIx64" mapped to %"PRIx64"", 
i_channels_src, pi_channels_map[i][0], pi_channels_map[i][1]);
-+                pi_order_dst[i_channels_src++] = pi_channels_map[i][1];
-+                order_mask |= pi_channels_map[i][1];
-             }
--        }
--        else
--        {
--            msg_Dbg( p_enc, "Creating default channel order for reordering");
--            /* Create default order  */
--            for( unsigned int i = 0; i < __MIN( i_order_max, 
(unsigned)p_sys->p_context->channels ); i++ )
--            {
--                if( i < sizeof(pi_channels_map)/sizeof(*pi_channels_map) )
--                {
--                    msg_Dbg( p_enc, "%d channel is %"PRIx64"", 
i_channels_src, pi_channels_map[i][1]);
--                    pi_order_dst[i_channels_src++] = pi_channels_map[i][1];
--                    order_mask |= pi_channels_map[i][1];
--                }
--            }
--        }
--        if( i_channels_src != p_context->channels )
-+
-+        if( i_channels_src != p_enc->fmt_out.audio.i_channels )
-             msg_Err( p_enc, "Channel layout not understood" );
- 
-         p_sys->i_channels_to_reorder =
-             aout_CheckChannelReorder( NULL, pi_order_dst, order_mask,
-                                       p_sys->pi_reorder_layout );
--#endif
- 
-         if ( p_enc->fmt_out.i_codec == VLC_CODEC_MP4A )
-         {
-@@ -897,7 +910,7 @@ int InitVideoEnc( vlc_object_t *p_this )
-     if( ret )
-     {
-         if( p_enc->fmt_in.i_cat != AUDIO_ES ||
--                (p_context->channels <= 2 && i_codec_id != AV_CODEC_ID_MP2
-+                (p_enc->fmt_out.audio.i_channels <= 2 && i_codec_id != 
AV_CODEC_ID_MP2
-                  && i_codec_id != AV_CODEC_ID_MP3) )
- errmsg:
-         {
-@@ -922,10 +935,14 @@ errmsg:
-             goto error;
-         }
- 
--        if( p_context->channels > 2 )
-+        if( p_enc->fmt_out.audio.i_channels > 2 )
-         {
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 24, 100 ))
-+            av_channel_layout_default( &p_context->ch_layout, 2 );
-+#else
-             p_context->channels = 2;
-             p_context->channel_layout = channel_mask[p_context->channels][1];
-+#endif
- 
-             /* Change fmt_in in order to ask for a channels conversion */
-             p_enc->fmt_in.audio.i_channels =
-@@ -1028,7 +1045,7 @@ errmsg:
-                                     p_context->frame_size :
-                                     AV_INPUT_BUFFER_MIN_SIZE;
-         p_sys->i_buffer_out = av_samples_get_buffer_size(NULL,
--                p_sys->p_context->channels, p_sys->i_frame_size,
-+                p_enc->fmt_out.audio.i_channels, p_sys->i_frame_size,
-                 p_sys->p_context->sample_fmt, DEFAULT_ALIGN);
-         p_sys->p_buffer = av_malloc( p_sys->i_buffer_out );
-         if ( unlikely( p_sys->p_buffer == NULL ) )
-@@ -1227,8 +1244,19 @@ static block_t *EncodeVideo( encoder_t *p_enc, picture
-         frame->pict_type = 0;
- 
-         frame->repeat_pict = p_pict->i_nb_fields - 2;
-+#if (LIBAVUTIL_VERSION_INT >= AV_VERSION_INT( 58, 7, 100 ))
-+        if (p_pict->b_progressive)
-+            frame->flags &= ~AV_FRAME_FLAG_INTERLACED;
-+        else
-+            frame->flags |= AV_FRAME_FLAG_INTERLACED;
-+        if (p_pict->b_top_field_first)
-+            frame->flags |= AV_FRAME_FLAG_TOP_FIELD_FIRST;
-+        else
-+            frame->flags &= ~AV_FRAME_FLAG_TOP_FIELD_FIRST;
-+#else
-         frame->interlaced_frame = !p_pict->b_progressive;
-         frame->top_field_first = !!p_pict->b_top_field_first;
-+#endif
- 
-         frame->format = p_sys->p_context->pix_fmt;
-         frame->width = p_sys->p_context->width;
-@@ -1278,13 +1306,17 @@ static block_t *handle_delay_buffer( encoder_t *p_enc,
- {
-     block_t *p_block = NULL;
-     //How much we need to copy from new packet
--    const size_t leftover = leftover_samples * p_sys->p_context->channels * 
p_sys->i_sample_bytes;
-+    const size_t leftover = leftover_samples * 
p_enc->fmt_out.audio.i_channels * p_sys->i_sample_bytes;
- 
-     av_frame_unref( p_sys->frame );
-     p_sys->frame->format     = p_sys->p_context->sample_fmt;
-     p_sys->frame->nb_samples = leftover_samples + p_sys->i_samples_delay;
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 24, 100 ))
-+    av_channel_layout_copy(&p_sys->frame->ch_layout, 
&p_sys->p_context->ch_layout);
-+#else
-     p_sys->frame->channel_layout = p_sys->p_context->channel_layout;
-     p_sys->frame->channels = p_sys->p_context->channels;
-+#endif
- 
-     p_sys->frame->pts        = date_Get( &p_sys->buffer_date ) * 
p_sys->p_context->time_base.den /
-                                 CLOCK_FREQ / p_sys->p_context->time_base.num;
-@@ -1301,7 +1333,7 @@ static block_t *handle_delay_buffer( encoder_t *p_enc,
-         // We need to deinterleave from p_aout_buf to p_buffer the leftover 
bytes
-         if( p_sys->b_planar )
-             aout_Deinterleave( p_sys->p_interleave_buf, p_sys->p_buffer,
--                p_sys->i_frame_size, p_sys->p_context->channels, 
p_enc->fmt_in.i_codec );
-+                p_sys->i_frame_size, p_enc->fmt_out.audio.i_channels, 
p_enc->fmt_in.i_codec );
-         else
-             memcpy( p_sys->p_buffer + buffer_delay, p_aout_buf->p_buffer, 
leftover);
- 
-@@ -1319,7 +1351,7 @@ static block_t *handle_delay_buffer( encoder_t *p_enc,
-         memset( p_sys->p_buffer + (leftover+buffer_delay), 0, padding_size );
-         buffer_delay += padding_size;
-     }
--    if( avcodec_fill_audio_frame( p_sys->frame, p_sys->p_context->channels,
-+    if( avcodec_fill_audio_frame( p_sys->frame, 
p_enc->fmt_out.audio.i_channels,
-             p_sys->p_context->sample_fmt, p_sys->b_planar ? 
p_sys->p_interleave_buf : p_sys->p_buffer,
-             p_sys->i_buffer_out,
-             DEFAULT_ALIGN) < 0 )
-@@ -1349,7 +1381,7 @@ static block_t *EncodeAudio( encoder_t *p_enc, block_t
- 
-     //i_bytes_left is amount of bytes we get
-     i_samples_left = p_aout_buf ? p_aout_buf->i_nb_samples : 0;
--    buffer_delay = p_sys->i_samples_delay * p_sys->i_sample_bytes * 
p_sys->p_context->channels;
-+    buffer_delay = p_sys->i_samples_delay * p_sys->i_sample_bytes * 
p_enc->fmt_out.audio.i_channels;
- 
-     //p_sys->i_buffer_out = p_sys->i_frame_size * chan * p_sys->i_sample_bytes
-     //Calculate how many bytes we would need from current buffer to fill frame
-@@ -1414,16 +1446,20 @@ static block_t *EncodeAudio( encoder_t *p_enc, block_t
-         p_sys->frame->pts        = date_Get( &p_sys->buffer_date ) * 
p_sys->p_context->time_base.den /
-                                     CLOCK_FREQ / 
p_sys->p_context->time_base.num;
- 
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 24, 100 ))
-+        av_channel_layout_copy(&p_sys->frame->ch_layout, 
&p_sys->p_context->ch_layout);
-+#else
-         p_sys->frame->channel_layout = p_sys->p_context->channel_layout;
-         p_sys->frame->channels = p_sys->p_context->channels;
-+#endif
- 
-         const int in_bytes = p_sys->frame->nb_samples *
--            p_sys->p_context->channels * p_sys->i_sample_bytes;
-+            p_enc->fmt_out.audio.i_channels* p_sys->i_sample_bytes;
- 
-         if( p_sys->b_planar )
-         {
-             aout_Deinterleave( p_sys->p_buffer, p_aout_buf->p_buffer,
--                               p_sys->frame->nb_samples, 
p_sys->p_context->channels, p_enc->fmt_in.i_codec );
-+                               p_sys->frame->nb_samples, 
p_enc->fmt_out.audio.i_channels, p_enc->fmt_in.i_codec );
- 
-         }
-         else
-@@ -1431,7 +1467,7 @@ static block_t *EncodeAudio( encoder_t *p_enc, block_t
-             memcpy(p_sys->p_buffer, p_aout_buf->p_buffer, in_bytes);
-         }
- 
--        if( avcodec_fill_audio_frame( p_sys->frame, 
p_sys->p_context->channels,
-+        if( avcodec_fill_audio_frame( p_sys->frame, 
p_enc->fmt_out.audio.i_channels,
-                                     p_sys->p_context->sample_fmt,
-                                     p_sys->p_buffer,
-                                     p_sys->i_buffer_out,
-@@ -1457,7 +1493,7 @@ static block_t *EncodeAudio( encoder_t *p_enc, block_t
-     if( p_aout_buf->i_nb_samples > 0 )
-     {
-        memcpy( p_sys->p_buffer + buffer_delay, p_aout_buf->p_buffer,
--               p_aout_buf->i_nb_samples * p_sys->i_sample_bytes * 
p_sys->p_context->channels);
-+               p_aout_buf->i_nb_samples * p_sys->i_sample_bytes * 
p_enc->fmt_out.audio.i_channels);
-        p_sys->i_samples_delay += p_aout_buf->i_nb_samples;
-     }
- 
-@@ -1475,9 +1511,8 @@ void EndVideoEnc( vlc_object_t *p_this )
-     av_frame_free( &p_sys->frame );
- 
-     vlc_avcodec_lock();
--    avcodec_close( p_sys->p_context );
--    vlc_avcodec_unlock();
-     avcodec_free_context( &p_sys->p_context );
-+    vlc_avcodec_unlock();
- 
- 
-     av_free( p_sys->p_interleave_buf );
Index: patches/patch-modules_codec_avcodec_fourcc_c
===================================================================
RCS file: patches/patch-modules_codec_avcodec_fourcc_c
diff -N patches/patch-modules_codec_avcodec_fourcc_c
--- patches/patch-modules_codec_avcodec_fourcc_c        21 Oct 2025 13:08:08 
-0000      1.4
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,16 +0,0 @@
-https://code.videolan.org/videolan/vlc/-/merge_requests/5304
-Index: modules/codec/avcodec/fourcc.c
---- modules/codec/avcodec/fourcc.c.orig
-+++ modules/codec/avcodec/fourcc.c
-@@ -183,7 +183,11 @@ static const struct vlc_avcodec_fourcc video_codecs[] 
-     { VLC_CODEC_TMV, AV_CODEC_ID_TMV },
-     { VLC_CODEC_V210, AV_CODEC_ID_V210 },
- #if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 54, 50, 100 ) && 
LIBAVCODEC_VERSION_MICRO >= 100
-+#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 142, 100 )
-+    { VLC_CODEC_VUYA, AV_CODEC_ID_RAWVIDEO },
-+#else
-     { VLC_CODEC_VUYA, AV_CODEC_ID_AYUV },
-+#endif
- #endif
-     /* AV_CODEC_ID_DPX */
-     { VLC_CODEC_MAD, AV_CODEC_ID_MAD },
Index: patches/patch-modules_codec_avcodec_video_c
===================================================================
RCS file: patches/patch-modules_codec_avcodec_video_c
diff -N patches/patch-modules_codec_avcodec_video_c
--- patches/patch-modules_codec_avcodec_video_c 21 Oct 2025 13:08:08 -0000      
1.6
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,72 +0,0 @@
-https://code.videolan.org/videolan/vlc/-/merge_requests/6656
-https://code.videolan.org/videolan/vlc/-/merge_requests/6659
-https://code.videolan.org/videolan/vlc/-/merge_requests/2814
-
-Index: modules/codec/avcodec/video.c
---- modules/codec/avcodec/video.c.orig
-+++ modules/codec/avcodec/video.c
-@@ -204,8 +204,7 @@ static int lavc_GetVideoFormat(decoder_t *dec, video_f
-     else if (ctx->time_base.num > 0 && ctx->time_base.den > 0)
-     {
-         fmt->i_frame_rate = ctx->time_base.den;
--        fmt->i_frame_rate_base = ctx->time_base.num
--                                 * __MAX(ctx->ticks_per_frame, 1);
-+        fmt->i_frame_rate_base = ctx->time_base.num;
-     }
- 
-     /* FIXME we should only set the known values and let the core decide
-@@ -327,12 +326,10 @@ static int lavc_UpdateVideoFormat(decoder_t *dec, AVCo
- 
-     /* always have date in fields/ticks units */
-     if(dec->p_sys->pts.i_divider_num)
--        date_Change(&dec->p_sys->pts, fmt_out.i_frame_rate *
--                                      __MAX(ctx->ticks_per_frame, 1),
-+        date_Change(&dec->p_sys->pts, fmt_out.i_frame_rate,
-                                       fmt_out.i_frame_rate_base);
-     else
--        date_Init(&dec->p_sys->pts, fmt_out.i_frame_rate *
--                                    __MAX(ctx->ticks_per_frame, 1),
-+        date_Init(&dec->p_sys->pts, fmt_out.i_frame_rate,
-                                     fmt_out.i_frame_rate_base);
- 
-     fmt_out.p_palette = dec->fmt_out.video.p_palette;
-@@ -625,11 +622,6 @@ static int InitVideoDecCommon( decoder_t *p_dec )
-     p_dec->pf_decode = DecodeVideo;
-     p_dec->pf_flush  = Flush;
- 
--    /* XXX: Writing input format makes little sense. */
--    if( p_context->profile != FF_PROFILE_UNKNOWN )
--        p_dec->fmt_in.i_profile = p_context->profile;
--    if( p_context->level != FF_LEVEL_UNKNOWN )
--        p_dec->fmt_in.i_level = p_context->level;
-     return VLC_SUCCESS;
- }
- 
-@@ -945,9 +937,11 @@ static vlc_tick_t interpolate_next_pts( decoder_t *p_d
-         p_sys->pts.i_divider_num == 0 )
-         return VLC_TICK_INVALID;
- 
-+#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(60, 12, 100))
-+    int i_tick = p_context->codec_descriptor->props & AV_CODEC_PROP_FIELDS ? 
2 : 1;
-+#else
-     int i_tick = p_context->ticks_per_frame;
--    if( i_tick <= 0 )
--        i_tick = 1;
-+#endif
- 
-     /* interpolate the next PTS */
-     return date_Increment( &p_sys->pts, i_tick + frame->repeat_pict );
-@@ -1426,8 +1420,13 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block
-         /* Hack to force display of still pictures */
-         p_pic->b_force = p_sys->b_first_frame;
-         p_pic->i_nb_fields = 2 + frame->repeat_pict;
-+#if (LIBAVUTIL_VERSION_INT >= AV_VERSION_INT(58, 7, 100))
-+        p_pic->b_progressive = !(frame->flags & AV_FRAME_FLAG_INTERLACED);
-+        p_pic->b_top_field_first = !!(frame->flags & 
AV_FRAME_FLAG_TOP_FIELD_FIRST);
-+#else
-         p_pic->b_progressive = !frame->interlaced_frame;
-         p_pic->b_top_field_first = frame->top_field_first;
-+#endif
- 
-         if (DecodeSidedata(p_dec, frame, p_pic))
-             i_pts = VLC_TICK_INVALID;
Index: patches/patch-modules_demux_avformat_demux_c
===================================================================
RCS file: patches/patch-modules_demux_avformat_demux_c
diff -N patches/patch-modules_demux_avformat_demux_c
--- patches/patch-modules_demux_avformat_demux_c        21 Oct 2025 13:08:08 
-0000      1.4
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,46 +0,0 @@
-https://code.videolan.org/videolan/vlc/-/merge_requests/6658
-https://code.videolan.org/videolan/vlc/-/merge_requests/5304
-
-Index: modules/demux/avformat/demux.c
---- modules/demux/avformat/demux.c.orig
-+++ modules/demux/avformat/demux.c
-@@ -112,6 +112,18 @@ static vlc_fourcc_t CodecTagToFourcc( uint32_t codec_t
- #endif
- }
- 
-+static inline void* GetStreamSideData(const AVStream *s, enum 
AVPacketSideDataType type)
-+{
-+#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 60, 29, 100 )
-+    const AVCodecParameters *cp = s->codecpar;
-+    const AVPacketSideData *psd =
-+        av_packet_side_data_get(cp->coded_side_data, cp->nb_coded_side_data, 
type);
-+    return psd ? psd->data : NULL;
-+#else
-+    return av_stream_get_side_data(s, type, NULL);
-+#endif
-+}
-+
- /*****************************************************************************
-  * Open
-  
*****************************************************************************/
-@@ -138,7 +150,7 @@ static void get_rotation(es_format_t *fmt, AVStream *s
-         else
-             fmt->video.orientation = ORIENT_NORMAL;
-     }
--    int32_t *matrix = (int32_t *)av_stream_get_side_data(s, 
AV_PKT_DATA_DISPLAYMATRIX, NULL);
-+    int32_t *matrix = GetStreamSideData(s, AV_PKT_DATA_DISPLAYMATRIX);
-     if( matrix ) {
-         angle = lround(av_display_rotation_get(matrix));
- 
-@@ -401,7 +413,11 @@ int avformat_OpenDemux( vlc_object_t *p_this )
-             es_format_Init( &es_fmt, AUDIO_ES, fcc );
-             es_fmt.i_original_fourcc = CodecTagToFourcc( cp->codec_tag );
-             es_fmt.i_bitrate = cp->bit_rate;
-+#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 24, 100 )
-+            es_fmt.audio.i_channels = cp->ch_layout.nb_channels;
-+#else
-             es_fmt.audio.i_channels = cp->channels;
-+#endif
-             es_fmt.audio.i_rate = cp->sample_rate;
-             es_fmt.audio.i_bitspersample = cp->bits_per_coded_sample;
-             es_fmt.audio.i_blockalign = cp->block_align;
Index: patches/patch-modules_demux_avformat_mux_c
===================================================================
RCS file: patches/patch-modules_demux_avformat_mux_c
diff -N patches/patch-modules_demux_avformat_mux_c
--- patches/patch-modules_demux_avformat_mux_c  21 Oct 2025 13:08:08 -0000      
1.4
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,17 +0,0 @@
-https://code.videolan.org/videolan/vlc/-/merge_requests/5304
-
-Index: modules/demux/avformat/mux.c
---- modules/demux/avformat/mux.c.orig
-+++ modules/demux/avformat/mux.c
-@@ -267,7 +267,11 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t 
-     {
-     case AUDIO_ES:
-         codecpar->codec_type = AVMEDIA_TYPE_AUDIO;
-+#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT( 59, 24, 100 )
-+        av_channel_layout_default( &codecpar->ch_layout, 
fmt->audio.i_channels );
-+#else
-         codecpar->channels = fmt->audio.i_channels;
-+#endif
-         codecpar->sample_rate = fmt->audio.i_rate;
-         stream->time_base = (AVRational){1, codecpar->sample_rate};
-         if (fmt->i_bitrate == 0) {
Index: patches/patch-modules_meta_engine_taglib_cpp
===================================================================
RCS file: patches/patch-modules_meta_engine_taglib_cpp
diff -N patches/patch-modules_meta_engine_taglib_cpp
--- patches/patch-modules_meta_engine_taglib_cpp        6 Jun 2025 05:45:15 
-0000       1.4
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,158 +0,0 @@
-Backport upstream fixes for taglib 2.x support and remove usages of member
-functions that were deprecated in taglib 1.x and removed in 2.x.
-Obtained from:
-https://code.videolan.org/videolan/vlc/-/commit/d2663d6c3fe3af76bdefd58367b4a45c598b83e4
-https://code.videolan.org/videolan/vlc/-/commit/ac59d0ba59ba800c52c0a92ec1d9576d2653dbe2
-https://code.videolan.org/videolan/vlc/-/commit/c404fdb24183031a419667639846edddca3401f8
-https://code.videolan.org/videolan/vlc/-/commit/ec29dfca1e59530dd412d779e0b045079b72ffb6
-Index: modules/meta_engine/taglib.cpp
---- modules/meta_engine/taglib.cpp.orig
-+++ modules/meta_engine/taglib.cpp
-@@ -125,7 +125,11 @@ VLCTagLib::ExtResolver<T>::ExtResolver(const std::stri
- template <class T>
- File *VLCTagLib::ExtResolver<T>::createFile(FileName fileName, bool, 
AudioProperties::ReadStyle) const
- {
-+#if defined(_WIN32) && TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    std::string filename = fileName.toString().to8Bit(true);
-+#else
-     std::string filename = std::string(fileName);
-+#endif
-     std::size_t namesize = filename.size();
- 
-     if (namesize > ext.length())
-@@ -180,12 +184,16 @@ class VlcIostream : public IOStream (public)
-         return m_stream->psz_location;
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    ByteVector readBlock(size_t length)
-+#else
-     ByteVector readBlock(ulong length)
-+#endif
-     {
-         ByteVector res(length, 0);
-         ssize_t i_read = vlc_stream_Read( m_stream, res.data(), length);
-         if (i_read < 0)
--            return ByteVector::null;
-+            return {};
-         else if ((size_t)i_read != length)
-             res.resize(i_read);
-         return res;
-@@ -196,11 +204,19 @@ class VlcIostream : public IOStream (public)
-         // Let's stay Read-Only for now
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    void insert(const ByteVector&, offset_t, size_t)
-+#else
-     void insert(const ByteVector&, ulong, ulong)
-+#endif
-     {
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    void removeBlock(offset_t, size_t)
-+#else
-     void removeBlock(ulong, ulong)
-+#endif
-     {
-     }
- 
-@@ -214,7 +230,11 @@ class VlcIostream : public IOStream (public)
-         return true;
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    void seek(offset_t offset, Position p)
-+#else
-     void seek(long offset, Position p)
-+#endif
-     {
-         uint64_t pos = 0;
-         switch (p)
-@@ -237,12 +257,20 @@ class VlcIostream : public IOStream (public)
-         return;
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    offset_t tell() const
-+#else
-     long tell() const
-+#endif
-     {
-         return m_previousPos;
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    offset_t length()
-+#else
-     long length()
-+#endif
-     {
-         uint64_t i_size;
-         if (vlc_stream_GetSize( m_stream, &i_size ) != VLC_SUCCESS)
-@@ -250,7 +278,11 @@ class VlcIostream : public IOStream (public)
-         return i_size;
-     }
- 
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+    void truncate(offset_t)
-+#else
-     void truncate(long)
-+#endif
-     {
-     }
- 
-@@ -465,7 +497,7 @@ static void ReadMetaFromASF( ASF::Tag* tag, demux_meta
- static void ReadMetaFromBasicTag(const Tag* tag, vlc_meta_t *dest)
- {
- #define SET( accessor, meta )                                                 
 \
--    if( !tag->accessor().isNull() && !tag->accessor().isEmpty() )             
 \
-+    if( !tag->accessor().isEmpty() )                                          
 \
-         vlc_meta_Set##meta( dest, tag->accessor().toCString(true) )
- #define SETINT( accessor, meta )                                              
 \
-     if( tag->accessor() )                                                     
 \
-@@ -806,15 +838,15 @@ static void ReadMetaFromMP4( MP4::Tag* tag, demux_meta
- {
-     MP4::Item list;
- #define SET( keyName, metaName )                                              
               \
--    if( tag->itemListMap().contains(keyName) )                                
               \
-+    if( tag->contains(keyName) )                                              
               \
-     {                                                                         
               \
--        list = tag->itemListMap()[keyName];                                   
               \
-+        list = tag->item(keyName);                                            
               \
-         vlc_meta_Set##metaName( p_meta, 
list.toStringList().front().toCString( true ) );     \
-     }
- #define SET_EXTRA( keyName, metaName )                                        
           \
--    if( tag->itemListMap().contains(keyName) )                                
  \
-+    if( tag->contains(keyName) )                                              
       \
-     {                                                                         
       \
--        list = tag->itemListMap()[keyName];                                   
  \
-+        list = tag->item(keyName);                                            
       \
-         vlc_meta_AddExtra( p_meta, metaName, 
list.toStringList().front().toCString( true ) ); \
-     }
- 
-@@ -824,9 +856,9 @@ static void ReadMetaFromMP4( MP4::Tag* tag, demux_meta
- #undef SET
- #undef SET_EXTRA
- 
--    if( tag->itemListMap().contains("covr") )
-+    if( tag->contains("covr") )
-     {
--        MP4::CoverArtList list = tag->itemListMap()["covr"].toCoverArtList();
-+        MP4::CoverArtList list = tag->item("covr").toCoverArtList();
-         const char *psz_format = list[0].format() == MP4::CoverArt::PNG ? 
"image/png" : "image/jpeg";
- 
-         msg_Dbg( p_demux_meta, "Found embedded art (%s) is %i bytes",
-@@ -1337,7 +1369,11 @@ static int WriteMeta( vlc_object_t *p_this )
-         if( RIFF::AIFF::File* riff_aiff = 
dynamic_cast<RIFF::AIFF::File*>(f.file()) )
-             WriteMetaToId3v2( riff_aiff->tag(), p_item );
-         else if( RIFF::WAV::File* riff_wav = 
dynamic_cast<RIFF::WAV::File*>(f.file()) )
-+#if TAGLIB_VERSION >= VERSION_INT(2, 0, 0)
-+            WriteMetaToId3v2( riff_wav->ID3v2Tag(), p_item );
-+#else
-             WriteMetaToId3v2( riff_wav->tag(), p_item );
-+#endif
-     }
-     else if( TrueAudio::File* trueaudio = 
dynamic_cast<TrueAudio::File*>(f.file()) )
-     {
Index: patches/patch-src_Makefile_am
===================================================================
RCS file: patches/patch-src_Makefile_am
diff -N patches/patch-src_Makefile_am
--- patches/patch-src_Makefile_am       19 Mar 2025 11:13:38 -0000      1.1
+++ /dev/null   1 Jan 1970 00:00:00 -0000
@@ -1,14 +0,0 @@
-- configure: look for backtrace() in libexecinfo
-  b3179e1e0993b8c15b735c93282c7675632c183c
-
-Index: src/Makefile.am
---- src/Makefile.am.orig
-+++ src/Makefile.am
-@@ -419,6 +419,7 @@ libvlccore_la_SOURCES += \
-       darwin/specific.c \
-       darwin/thread.c
- else
-+libvlccore_la_LIBADD += $(LIBEXECINFO)
- libvlccore_la_SOURCES += \
-       posix/dirs.c \
-       posix/error.c \
Index: pkg/PLIST-main
===================================================================
RCS file: /cvs/ports/x11/vlc/pkg/PLIST-main,v
retrieving revision 1.58
diff -u -p -u -p -r1.58 PLIST-main
--- pkg/PLIST-main      28 Oct 2025 09:39:55 -0000      1.58
+++ pkg/PLIST-main      9 Jan 2026 04:06:55 -0000
@@ -267,6 +267,8 @@ lib/vlc/plugins/codec/
 @so lib/vlc/plugins/codec/libtextst_plugin.so
 @so lib/vlc/plugins/codec/libttml_plugin.so
 @so lib/vlc/plugins/codec/libuleaddvaudio_plugin.so
+@so lib/vlc/plugins/codec/libvaapi_drm_plugin.so
+@so lib/vlc/plugins/codec/libvaapi_plugin.so
 @so lib/vlc/plugins/codec/libvorbis_plugin.so
 @so lib/vlc/plugins/codec/libwebvtt_plugin.so
 @so lib/vlc/plugins/codec/libx26410b_plugin.so
@@ -296,6 +298,7 @@ lib/vlc/plugins/demux/
 @so lib/vlc/plugins/demux/libdemuxdump_plugin.so
 @so lib/vlc/plugins/demux/libdiracsys_plugin.so
 @so lib/vlc/plugins/demux/libdirectory_demux_plugin.so
+@so lib/vlc/plugins/demux/libdmxmus_plugin.so
 @so lib/vlc/plugins/demux/libes_plugin.so
 @so lib/vlc/plugins/demux/libflacsys_plugin.so
 @so lib/vlc/plugins/demux/libh26x_plugin.so
@@ -434,6 +437,8 @@ lib/vlc/plugins/stream_out/
 lib/vlc/plugins/text_renderer/
 @so lib/vlc/plugins/text_renderer/libfreetype_plugin.so
 @so lib/vlc/plugins/text_renderer/libtdummy_plugin.so
+lib/vlc/plugins/vaapi/
+@so lib/vlc/plugins/vaapi/libvaapi_filters_plugin.so
 lib/vlc/plugins/video_chroma/
 @so lib/vlc/plugins/video_chroma/libchain_plugin.so
 @so lib/vlc/plugins/video_chroma/libgrey_yuv_plugin.so
@@ -494,6 +499,8 @@ lib/vlc/plugins/video_output/
 @so lib/vlc/plugins/video_output/libegl_x11_plugin.so
 @so lib/vlc/plugins/video_output/libflaschen_plugin.so
 @so lib/vlc/plugins/video_output/libgl_plugin.so
+@so lib/vlc/plugins/video_output/libglconv_vaapi_drm_plugin.so
+@so lib/vlc/plugins/video_output/libglconv_vaapi_x11_plugin.so
 @so lib/vlc/plugins/video_output/libglx_plugin.so
 @so lib/vlc/plugins/video_output/libvdummy_plugin.so
 @so lib/vlc/plugins/video_output/libvmem_plugin.so
@@ -581,9 +588,7 @@ share/locale/am_ET/LC_MESSAGES/
 share/locale/am_ET/LC_MESSAGES/vlc.mo
 share/locale/an/LC_MESSAGES/vlc.mo
 share/locale/ar/LC_MESSAGES/vlc.mo
-share/locale/as_IN/
-share/locale/as_IN/LC_MESSAGES/
-share/locale/as_IN/LC_MESSAGES/vlc.mo
+share/locale/as/LC_MESSAGES/vlc.mo
 share/locale/ast/LC_MESSAGES/vlc.mo
 share/locale/be/LC_MESSAGES/vlc.mo
 share/locale/bg/LC_MESSAGES/vlc.mo
@@ -708,7 +713,7 @@ share/locale/zh_CN/LC_MESSAGES/vlc.mo
 share/locale/zh_TW/LC_MESSAGES/vlc.mo
 share/locale/zu/LC_MESSAGES/vlc.mo
 share/metainfo/
-share/metainfo/vlc.appdata.xml
+share/metainfo/org.videolan.vlc.appdata.xml
 share/vlc/
 share/vlc/lua/
 share/vlc/lua/http/

Reply via email to