diff options
| author | root <root@alpha.trunkmasters.com> | 2026-08-13 03:04:49 -0500 |
|---|---|---|
| committer | root <root@alpha.trunkmasters.com> | 2026-08-13 03:04:49 -0500 |
| commit | 00a5031b2e58fb36fc981fe226565880b4798a8b (patch) | |
| tree | b6ce2d2b06f7a32a17f7304fa0c94d5790820783 /media-libs | |
| parent | ec560e4b511b5d7cb09adbd406de3ddb8386156f (diff) | |
| download | baldeagleos-repo-00a5031b2e58fb36fc981fe226565880b4798a8b.tar.gz baldeagleos-repo-00a5031b2e58fb36fc981fe226565880b4798a8b.tar.xz baldeagleos-repo-00a5031b2e58fb36fc981fe226565880b4798a8b.zip | |
Adding metadata
Diffstat (limited to 'media-libs')
| -rw-r--r-- | media-libs/mlt/Manifest | 1 | ||||
| -rw-r--r-- | media-libs/mlt/files/mlt-7.40.0-ffmpeg-9.patch | 158 | ||||
| -rw-r--r-- | media-libs/mlt/mlt-7.34.1-r1.ebuild | 177 | ||||
| -rw-r--r-- | media-libs/mlt/mlt-7.40.0.ebuild | 1 |
4 files changed, 159 insertions, 178 deletions
diff --git a/media-libs/mlt/Manifest b/media-libs/mlt/Manifest index 923337742912..ccd0af2cc1bb 100644 --- a/media-libs/mlt/Manifest +++ b/media-libs/mlt/Manifest @@ -1,3 +1,2 @@ -DIST mlt-7.34.1.tar.gz 1817867 BLAKE2B 45a422b12dca99fcd95af9f2c540497e2aa97210f6674726884b0eb8d1f321706679512675ff21993c997d9332be7128ce93f689c8f7612d68952ea87e6c56e5 SHA512 de71d698e8adc03d4e3c66c5e1d4dbf2e91848b2260e29084401a56d49493f28671c5c0979922dc46864ee3991ef35cab2cd9be6b88bb67dc49e36488f87050e DIST mlt-7.38.0.tar.gz 6674009 BLAKE2B 4843dbca30cdec26b3b340901ca1a3603bb9ce6565620218d017f0b848e1991fcc3cf0fe6354ec95d9c557cbcfd6e9f0e5a61f3aa9653b1c92822a4fb941af8c SHA512 762f7470eb294e6923206d9793ec65341eb6712c5b0251366dcd565ef84f59a0dc9c01a0695ce2c6b2f427d3a99fc38207ccf92905f105325720af9ce7e534b8 DIST mlt-7.40.0.tar.gz 6775875 BLAKE2B e2eb028abc339e6b39a9ea1656e351bd137430d5a736552a79eb4ce7ca904a097804b9e2aed71cbf401983e9b436913e113d3d0a9dfbf76ce77116a00c16c11e SHA512 f595f18777b0a69aff18270176f528865a38083439a320e206eba381b9ee8de9efc78bf1ae65355a6fd72265d91d2487f7ac54e57dcbdef1e1152049d2ceed25 diff --git a/media-libs/mlt/files/mlt-7.40.0-ffmpeg-9.patch b/media-libs/mlt/files/mlt-7.40.0-ffmpeg-9.patch new file mode 100644 index 000000000000..3f1e47739b6e --- /dev/null +++ b/media-libs/mlt/files/mlt-7.40.0-ffmpeg-9.patch @@ -0,0 +1,158 @@ +From 06c4785f951c087c700de942362d1d1c68ffe500 Mon Sep 17 00:00:00 2001 +From: Dan Dennedy <dan@dennedy.org> +Date: Thu, 6 Aug 2026 17:14:24 -0700 +Subject: [PATCH] Fix #1280 support for FFmpeg 9 (#1281) + +--- + src/modules/avformat/consumer_avformat.c | 61 ++++++++++++++++++++-- + src/modules/avformat/consumer_avformat.yml | 6 ++- + 2 files changed, 63 insertions(+), 4 deletions(-) + +diff --git a/src/modules/avformat/consumer_avformat.c b/src/modules/avformat/consumer_avformat.c +index d5ab5f1cd..cebd89f0e 100644 +--- a/src/modules/avformat/consumer_avformat.c ++++ b/src/modules/avformat/consumer_avformat.c +@@ -629,7 +629,8 @@ static void apply_properties(void *obj, mlt_properties properties, int flags) + || (opt_name[0] == 'a' && (flags & AV_OPT_FLAG_AUDIO_PARAM)))) + opt = av_opt_find(obj, ++opt_name, NULL, flags, search_flags); + // Apply option if found +- if (opt && strcmp(opt_name, "channel_layout") && strcmp(opt_name, "frame_duration")) ++ if (opt && strcmp(opt_name, "channel_layout") && strcmp(opt_name, "frame_duration") ++ && strcmp(opt_name, "dc")) + av_opt_set(obj, opt_name, mlt_properties_get_value(properties, i), search_flags); + } + } +@@ -680,7 +681,6 @@ static int pick_sample_fmt(mlt_properties properties, const AVCodec *codec) + { + int sample_fmt = AV_SAMPLE_FMT_S16; + const char *format = mlt_properties_get(properties, "mlt_audio_format"); +- const int *p = codec->sample_fmts; + const char *sample_fmt_str = mlt_properties_get(properties, "sample_fmt"); + + if (sample_fmt_str) +@@ -699,13 +699,29 @@ static int pick_sample_fmt(mlt_properties properties, const AVCodec *codec) + else if (!strcmp(format, "float")) + sample_fmt = AV_SAMPLE_FMT_FLTP; + } ++#if LIBAVCODEC_VERSION_INT >= ((61 << 16) + (13 << 8) + 100) ++ const enum AVSampleFormat *sample_fmts = NULL; ++ avcodec_get_supported_config(NULL, ++ codec, ++ AV_CODEC_CONFIG_SAMPLE_FORMAT, ++ 0, ++ (const void **) &sample_fmts, ++ NULL); ++ const int *p = (const int *) sample_fmts; ++#else ++ const int *p = codec->sample_fmts; ++#endif + // check if codec supports our mlt_audio_format +- for (; *p != -1; p++) { ++ for (; p && *p != -1; p++) { + if (*p == sample_fmt) + return sample_fmt; + } + // no match - pick first one we support ++#if LIBAVCODEC_VERSION_INT >= ((61 << 16) + (13 << 8) + 100) ++ for (p = (const int *) sample_fmts; p && *p != -1; p++) { ++#else + for (p = codec->sample_fmts; *p != -1; p++) { ++#endif + switch (*p) { + case AV_SAMPLE_FMT_U8: + case AV_SAMPLE_FMT_S16: +@@ -980,9 +996,25 @@ static AVStream *add_video_stream(mlt_consumer consumer, + c->framerate = av_inv_q(c->time_base); + + // Default to the codec's first pix_fmt if possible. ++#if LIBAVCODEC_VERSION_INT >= ((61 << 16) + (13 << 8) + 100) ++ { ++ const enum AVPixelFormat *video_pix_fmts = NULL; ++ if (codec) ++ avcodec_get_supported_config(NULL, ++ codec, ++ AV_CODEC_CONFIG_PIX_FORMAT, ++ 0, ++ (const void **) &video_pix_fmts, ++ NULL); ++ c->pix_fmt = pix_fmt ? av_get_pix_fmt(pix_fmt) ++ : codec ? (video_pix_fmts ? video_pix_fmts[0] : AV_PIX_FMT_YUV422P) ++ : AV_PIX_FMT_YUV420P; ++ } ++#else + c->pix_fmt = pix_fmt ? av_get_pix_fmt(pix_fmt) + : codec ? (codec->pix_fmts ? codec->pix_fmts[0] : AV_PIX_FMT_YUV422P) + : AV_PIX_FMT_YUV420P; ++#endif + + if (AV_PIX_FMT_VAAPI == c->pix_fmt) { + int result = init_vaapi(properties, c); +@@ -1082,7 +1114,9 @@ static AVStream *add_video_stream(mlt_consumer consumer, + c->rc_override_count = i; + if (!c->rc_initial_buffer_occupancy) + c->rc_initial_buffer_occupancy = c->rc_buffer_size * 3 / 4; ++#if LIBAVCODEC_VERSION_INT < ((62 << 16) + (25 << 8) + 100) + c->intra_dc_precision = mlt_properties_get_int(properties, "dc") - 8; ++#endif + + // Setup dual-pass + i = mlt_properties_get_int(properties, "pass"); +@@ -1199,6 +1233,26 @@ static int open_video(mlt_properties properties, + AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM); + } + ++#if LIBAVCODEC_VERSION_INT >= ((61 << 16) + (13 << 8) + 100) ++ if (codec) { ++ const enum AVPixelFormat *pix_fmts = NULL; ++ avcodec_get_supported_config(NULL, ++ codec, ++ AV_CODEC_CONFIG_PIX_FORMAT, ++ 0, ++ (const void **) &pix_fmts, ++ NULL); ++ if (pix_fmts) { ++ const enum AVPixelFormat *p = pix_fmts; ++ for (; *p != -1; p++) { ++ if (*p == video_enc->pix_fmt) ++ break; ++ } ++ if (*p == -1) ++ video_enc->pix_fmt = pix_fmts[0]; ++ } ++ } ++#else + if (codec && codec->pix_fmts) { + const enum AVPixelFormat *p = codec->pix_fmts; + for (; *p != -1; p++) { +@@ -1208,6 +1262,7 @@ static int open_video(mlt_properties properties, + if (*p == -1) + video_enc->pix_fmt = codec->pix_fmts[0]; + } ++#endif + + const AVPixFmtDescriptor *srcDesc = av_pix_fmt_desc_get(video_enc->pix_fmt); + if (srcDesc->flags & AV_PIX_FMT_FLAG_RGB) { +diff --git a/src/modules/avformat/consumer_avformat.yml b/src/modules/avformat/consumer_avformat.yml +index 989466b55..f3644206c 100644 +--- a/src/modules/avformat/consumer_avformat.yml ++++ b/src/modules/avformat/consumer_avformat.yml +@@ -3,7 +3,7 @@ type: consumer + identifier: avformat + title: FFmpeg Output + version: 7 +-copyright: Copyright (C) 2003-2019 Meltytech, LLC ++copyright: Copyright (C) 2003-2026 Meltytech, LLC + license: LGPL + language: en + url: http://www.ffmpeg.org/ +@@ -452,6 +452,10 @@ parameters: + - identifier: dc + title: Intra DC precision + type: integer ++ description: > ++ Sets intra_dc_precision for MPEG-2 encoding. The value is offset by 8, ++ so the default of 8 means precision 0 (8-bit). Only relevant for ++ MPEG-2; ignored on FFmpeg 8.0 and later. + default: 8 + + - identifier: muxdelay diff --git a/media-libs/mlt/mlt-7.34.1-r1.ebuild b/media-libs/mlt/mlt-7.34.1-r1.ebuild deleted file mode 100644 index 4b25e0a99fe1..000000000000 --- a/media-libs/mlt/mlt-7.34.1-r1.ebuild +++ /dev/null @@ -1,177 +0,0 @@ -# Copyright 1999-2025 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -PYTHON_COMPAT=( python3_{13..14} ) -inherit python-single-r1 cmake flag-o-matic - -DESCRIPTION="Open source multimedia framework for television broadcasting" -HOMEPAGE="https://www.mltframework.org/" -SRC_URI="https://github.com/mltframework/${PN}/releases/download/v${PV}/${P}.tar.gz" - -LICENSE="GPL-3" -SLOT="0/7" -KEYWORDS="amd64 arm64 ~loong ~ppc64 ~riscv ~x86" -IUSE="debug ffmpeg frei0r gtk jack libsamplerate opencv opengl python qt6 -rtaudio rubberband sdl test vdpau vidstab vorbis xine xml" - -REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" - -# Needs unpackaged 'kwalify' -RESTRICT="test" - -# rtaudio will use OSS on non linux OSes -# Qt already needs FFTW/PLUS so let's just always have it on to ensure -# MLT is useful: bug #603168. -DEPEND=" - >=media-libs/libebur128-1.2.2:= - sci-libs/fftw:3.0= - ffmpeg? ( media-video/ffmpeg:0=[vdpau?] ) - frei0r? ( media-plugins/frei0r-plugins ) - gtk? ( - media-libs/libexif - x11-libs/pango - ) - jack? ( - >=dev-libs/libxml2-2.5:= - media-libs/ladspa-sdk - virtual/jack - ) - libsamplerate? ( >=media-libs/libsamplerate-0.1.2 ) - opencv? ( - >=media-libs/opencv-4.5.1:=[contrib] - || ( - media-libs/opencv[ffmpeg] - media-libs/opencv[gstreamer] - ) - ) - opengl? ( - media-libs/libglvnd - media-video/movit - ) - python? ( ${PYTHON_DEPS} ) - qt6? ( - dev-qt/qt5compat:6 - dev-qt/qtbase:6[gui,network,opengl,widgets,xml] - dev-qt/qtsvg:6 - media-libs/libexif - x11-libs/libX11 - ) - rtaudio? ( - >=media-libs/rtaudio-4.1.2 - kernel_linux? ( media-libs/alsa-lib ) - ) - rubberband? ( media-libs/rubberband:= ) - sdl? ( - media-libs/libsdl2[X,opengl,video] - media-libs/sdl2-image - ) - vidstab? ( media-libs/vidstab ) - vorbis? ( media-libs/libvorbis ) - xine? ( >=media-libs/xine-lib-1.1.2_pre20060328-r7 ) - xml? ( >=dev-libs/libxml2-2.5:= ) -" -# java? ( >=virtual/jre-1.8:* ) -# perl? ( dev-lang/perl ) -# php? ( dev-lang/php ) -# ruby? ( ${RUBY_DEPS} ) -# sox? ( media-sound/sox ) -# tcl? ( dev-lang/tcl:0= ) -RDEPEND="${DEPEND}" -BDEPEND=" - virtual/pkgconfig - python? ( >=dev-lang/swig-2.0 ) -" - -DOCS=( AUTHORS NEWS README.md ) - -PATCHES=( - # downstream - "${FILESDIR}"/${PN}-6.10.0-swig-underlinking.patch - "${FILESDIR}"/${PN}-6.22.1-no_lua_bdepend.patch - "${FILESDIR}"/${PN}-7.0.1-cmake-symlink.patch -) - -pkg_setup() { - use python && python-single-r1_pkg_setup -} - -src_prepare() { - # Respect CFLAGS LDFLAGS when building shared libraries. Bug #308873 - if use python; then - sed -i "/mlt.so/s/ -lmlt++ /& ${CFLAGS} ${LDFLAGS} /" src/swig/python/build || die - python_fix_shebang src/swig/python - fi - - cmake_src_prepare -} - -src_configure() { - # Workaround for bug #919981 - append-ldflags $(test-flags-CCLD -Wl,--undefined-version) - - local mycmakeargs=( - -DCMAKE_SKIP_RPATH=ON - -DCLANG_FORMAT=OFF - -DGPL=ON - -DGPL3=ON - -DMOD_QT=OFF - -DMOD_GLAXNIMATE=OFF - -DMOD_KDENLIVE=ON - -DMOD_PLUS=ON - -DMOD_SDL1=OFF - -DMOD_SOX=OFF - -DMOD_SPATIALAUDIO=OFF # TODO: package libspatialaudio - -DUSE_LV2=OFF # TODO - -DUSE_VST2=OFF # TODO - -DMOD_AVFORMAT=$(usex ffmpeg) - -DMOD_FREI0R=$(usex frei0r) - -DMOD_GDK=$(usex gtk) - -DMOD_JACKRACK=$(usex jack) - -DMOD_RESAMPLE=$(usex libsamplerate) - -DMOD_OPENCV=$(usex opencv) - -DMOD_MOVIT=$(usex opengl) - -DMOD_QT6=$(usex qt6) - -DMOD_GLAXNIMATE_QT6=$(usex qt6) - -DMOD_RTAUDIO=$(usex rtaudio) - -DMOD_RUBBERBAND=$(usex rubberband) - -DMOD_SDL2=$(usex sdl) - -DBUILD_TESTING=OFF # Needs unpackaged 'kwalify'; restricted anyway. - -DMOD_VIDSTAB=$(usex vidstab) - -DMOD_VORBIS=$(usex vorbis) - -DMOD_XINE=$(usex xine) - -DMOD_XML=$(usex xml) - ) - - # TODO: rework upstream CMake to allow controlling MMX/SSE/SSE2 - # TODO: add swig language bindings? - # see also https://www.mltframework.org/twiki/bin/view/MLT/ExtremeMakeover - - if use python; then - mycmakeargs+=( - -DSWIG_PYTHON=ON - -DPython3_EXECUTABLE="${PYTHON}" - ) - fi - - cmake_src_configure -} - -src_install() { - cmake_src_install - - insinto /usr/share/${PN} - doins -r demo - - # - # Install SWIG bindings - # - - docinto swig - - if use python; then - dodoc "${S}"/src/swig/python/play.py - python_optimize - fi -} diff --git a/media-libs/mlt/mlt-7.40.0.ebuild b/media-libs/mlt/mlt-7.40.0.ebuild index 5242c022ad6a..3ad42142868c 100644 --- a/media-libs/mlt/mlt-7.40.0.ebuild +++ b/media-libs/mlt/mlt-7.40.0.ebuild @@ -95,6 +95,7 @@ PATCHES=( "${FILESDIR}"/${PN}-6.10.0-swig-underlinking.patch "${FILESDIR}"/${PN}-6.22.1-no_lua_bdepend.patch "${FILESDIR}"/${PN}-7.0.1-cmake-symlink.patch + "${FILESDIR}"/${P}-ffmpeg-9.patch # in git master ) pkg_setup() { |
