Shared FFmpeg fixes for the VMAFx and Pelorus projects
Consumers apply this series first and carry only their own feature patches
ffmpeg-patches tracks FFmpeg master (series.txt). Its name
describes the repository's contents: FFmpeg patches shared by the VMAFx and Pelorus
projects (ADR-0001); pronounce it
"eff-eff-em-peg patches".
The repository moved from the VMAFx GitHub organisation to vidiko on 2026-11-20 with its name unchanged; links to github.com/VMAFx/ffmpeg-patches redirect.
Each patch's state is recorded in the .toml sidecar beside it.
📖 Architectural Decision Records · ADR-0001: Shared Fix Series
A fix lives here once, so consumers do not maintain their own copies. See ADR-0001 for that decision and How it works for the patch lifecycle.
This repository ships patches only and builds nothing
(see the build target in Makefile).
. ./base.env
git clone --branch "$FFMPEG_TAG" --depth 1 "$FFMPEG_REMOTE" ffmpeg
test "$(git -C ffmpeg rev-parse HEAD)" = "$FFMPEG_COMMIT"
python3 scripts/series.py apply --expect-base ffmpegapply checks each patch and prints one result per patch. In
apply_one in scripts/series.py, it skips
git am --3way only when the forward application check fails and all added
lines are already in the tree. Otherwise, it attempts git am --3way
without your git configuration and reports the result:
applied: the patch appliedconflict: it did not; the run stops unless--keep-goingis givenupstream: its added lines are already in the tree, so it is a drop candidate; on the pinned release this is an errornot-tried: the patch was not attempted because a preceding patch conflicted and--keep-goingwas not given
The series is a list of FFmpeg fixes in git format-patch form, applied in
order onto one pinned FFmpeg release. Its
patches/NNNN-slug.toml sidecars record each patch's status:
unsubmitted, submitted, merged or rejected, with an upstream
reference once submitted. unsubmitted means no submission yet. Fixes are
written to go upstream; rejected, withdrawn or replaced submissions may
remain only while the pinned base needs the fix and need not be submitted
again. The series maintainer drops a patch once its fixes have merged
upstream and a release containing them is pinned.
Consumers:
%%{init: {'theme': 'base', 'themeVariables': {'fontSize': '15px', 'primaryColor': '#111a35', 'primaryTextColor': '#e2e8f0', 'primaryBorderColor': '#3b82f6', 'lineColor': '#3b82f6', 'edgeLabelBackground': '#111a35', 'tertiaryColor': '#0b1020'}}}%%
flowchart TD
found["Fix found in a consumer<br/>or in this series"]:::input
series["Add patch to series<br/>for pinned FFmpeg release"]:::step
upstream["Submit fix upstream<br/>where applicable"]:::step
consumers["Consumers apply shared series"]:::step
features["Apply own feature patches"]:::step
merged["If upstream merges the fixes"]:::step
pin["Pin a release containing the fix"]:::step
retained["Keep rejected or withdrawn fix<br/>while pinned base needs it"]:::step
drop["Drop patch from series"]:::step
found --> series
series --> upstream
series --> consumers
consumers --> features
upstream --> merged
upstream -->|rejected or withdrawn| retained
retained -->|pinned base no longer needs fix| drop
merged --> pin
pin --> drop
classDef input fill:#0b1020,stroke:#06b6d4,stroke-width:2px,color:#e2e8f0
classDef step fill:#111a35,stroke:#3b82f6,stroke-width:2px,color:#e2e8f0
| Path | Role |
|---|---|
base.env |
Pinned FFmpeg release: remote, tag and the commit the tag must peel to |
series.txt |
Patch order; the series is cumulative |
patches/NNNN-slug.patch |
One fix, generated by git format-patch |
patches/NNNN-slug.toml |
Its metadata: status, upstream link, consumers, origin |
upstream-contributions.json |
Upstream pull-request records and states; source of the contributions table |
scripts/series.py |
check, apply, export, the coverage and warnings gates, the contributions table and release notes |
scripts/upstream_drift.py |
Compares upstream-contributions.json with the FFmpeg forge |
scripts/upstream_links.py |
Fills linked upstream issues and related pulls, and checks open pulls for overlaps |
scripts/upstream_links_parse.py |
Parses upstream records, issue references and overlap evidence |
scripts/upstream_links_forge.py |
Fetches forge pages within request and scan limits |
scripts/upstream_links_scan.py |
Plans requests and inspects pull overlap candidates |
scripts/upstream_links_manifest.py |
Fills and atomically publishes contribution manifests |
scripts/consumer_stacks.py |
Applies each consumer's patch stack on top of the applied series |
scripts/graph_check.py |
Reports conversion filters FFmpeg inserted on its own into a filtergraph |
scripts/tonemap_parity.py |
Colour difference, time and VRAM of tone-map filter chains against vf_libplacebo (ADR-0002) |
Metadata keys:
status:unsubmitted,submitted,mergedorrejectedupstream: link to the FFmpeg pull request or patch; required unlessunsubmittedconsumers: projects that need the fix; every consumer still applies the whole seriesorigin,notes: where the patch came from, and anything a maintainer must know
The series carries one form of each patch: the one for the pinned release.
The upstream link records the submission, which may target master or a
release branch. For a submitted patch, record optional
master_form = { base = "<40-hex>", head = "<40-hex>" } only if the PR's
base branch is master, using the PR API's current merge_base as base and
head.sha as head.
Update these ids whenever the PR is pushed again. For a merged patch,
optional upstream_commit = "<40-hex>" must name the commit carrying the fix
on FFmpeg master. All ids must be full lowercase commit hashes.
A patch whose release form has no single master form (for example, one split
into several upstream pull requests) records
release_only = "<reason>"; it excludes master_form and upstream_commit.
For a PR against a release branch, record release_only with a reason.
Once the PR is merged and the fix is on master as one commit, replace
release_only by hand with upstream_commit naming that commit. Otherwise,
keep release_only, for example if the fix spans several master pull requests.
The daily upstream drift check fails when a recorded master_form no longer
matches the PR's head or merge base on the forge. An unsubmitted patch whose
fix travels in another author's PR records it as
covered_by = "https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/<number>"; the
daily check fails once that PR merges or closes.
Before pushing or opening a pull request, scan the committed fix and callers of its targets:
# Fetch the upstream base so both master and topic resolve as local refs:
git -C /path/to/FFmpeg fetch origin master:master
# A shallow clone needs enough history for the merge base; deepen it if merge-base fails:
git -C /path/to/FFmpeg fetch --unshallow origin # or: fetch --deepen=<commits> origin
# Sweep from the merge base so upstream-only changes are excluded:
python3 scripts/variant_sweep.py -C /path/to/FFmpeg --class unchecked-return \
"$(git -C /path/to/FFmpeg merge-base master topic)" topic -o sweep.mdThe report records full base and head commit IDs. Targets combine callees whose return values appear in recognized error checks on added lines with functions whose bodies contain added lines. The scan covers touched C/header files and C files in the head revision mentioning those targets. It reports discarded calls and checks that normalize an error to -1 or an AVERROR_ value. Explicit (void) calls are intentional and excluded. This lexical scan supports review; inspect the surrounding control flow when deciding each row.
Replace every TODO disposition with one of:
fold: same bug class and same file as the fix; fold the correction into this pull request.follow-up: <reproducer path>: otherwise, record the ancestor reproducer path in the evidence and track the correction separately.no-variant: <reason>: the row is not a variant of the fixed bug, for example an error check that predates the series and already handles the error; state the reason and keep the analysis in the evidence.
Keep the PR body unchanged unless a variant is folded into the fix. After folding, regenerate the report for the new head and review its rows again. A report with no findings ends with no hits.
Pass the reviewed report before positional arguments to both commands (run these inside the FFmpeg clone):
/path/to/ffmpeg-patches/scripts/ffmpeg-forgejo push --sweep /path/to/sweep.md topic
/path/to/ffmpeg-patches/scripts/ffmpeg-forgejo pr --sweep /path/to/sweep.md topic "Fix title" /path/to/body.mdBoth commands refuse a missing report, a head that differs from the local branch, or an unresolved or unknown disposition before contacting the forge or pushing. --sweep may be interleaved with --lease on push or --overlap-ok on pr. ffmpeg-forgejo overlap [--overlap-ok <number>]... <branch> lists every own open pull sharing a file with the branch diff against the fetched base (exit 77 when any, 0 when none, 1 when not proven). The base is fetched into a private ref (the caller's FETCH_HEAD is untouched), the own open pulls are listed oldest first and listed again after the file checks (up to 3 rounds; unequal listings exit 1), and every shared path of each pull is printed.
Both commands also exit 74 when the helper is not scripts/ffmpeg-forgejo of a Git checkout, run directly or through a symlink, so an installed copy that predates a newer check cannot push or open a pull request. Install the helper as a symlink to the repository script; make doctor checks the installation.
The forge helper scripts share configuration through environment variables, implemented in scripts/forge_settings.py and verified by tests/test_forge_settings.py:
FFMPEG_FORGEJO_HOST: forge URL (default:https://code.ffmpeg.org).FFMPEG_FORGEJO_REPO: repository path (default:FFmpeg/FFmpeg).FFMPEG_FORGEJO_BOT_REVIEWER: bot reviewer login (default:Forgejo_Fairy).FFMPEG_FORGEJO_LOGIN: user login on the forge; when unset, discovered from/userwith the keyring token.
- Apply the series onto the pinned release, as above.
- Commit, amend or reorder in that checkout. Keep FFmpeg's commit message
style and add a
Signed-off-bytrailer. - Regenerate:
python3 scripts/series.py export ffmpeg. Metadata follows its patch when the number changes. - Write or update
patches/NNNN-slug.tomland runmake test, thenmake lengths FFMPEG_TREE=ffmpegto catch a function grown past the 60-line cap (HISS-04) before it reaches CI. - If a patch name or number changes, rename any old
.tomlsidecar that export left behind after a slug change to match. Update matching paths and comments inREUSE.toml, if present, and any existing record inupstream-contributions.json. Update current-series references in sidecar text,README.md,docs/,tests/(including numbered patch lookups), and.github/workflows/; preserve historical references and synthetic fixture names. Regenerate the table withpython3 scripts/series.py contributions --write, then runpython3 scripts/series.py check. It reports sidecar, contribution record and libplacebo credit mismatches; review other REUSE paths and references by hand. Add a record when submitting a patch upstream; keep existing records in sync when itsstatusorupstreamlink changes, then regenerate the table.
series.yml always runs the series check, lint and unit tests on pull requests. Its scope job compares the pull request head with its merge base: ffmpeg selects the pinned-base apply, regeneration, clang-tidy, build, FATE, coverage and warning gates; parity selects the GPU parity step within that job; macos selects the Metal build and warning gate and runs for every change to the patches, series.txt, base.env or the gate itself, because that job refuses clang warnings in every file the series changes. Both heavy jobs always start, so they stay required checks; outside the scope of a change they skip every step, so a docs-only change finishes them in seconds. When the scope job itself fails, both heavy jobs run in full, and the scope job is a required check of its own. Pushes to main and release calls run the full set (scope --full); draft pull requests still fail the check job until marked ready for review.
The checks cover:
make test: series check, ruff, mutable defaults and the unit tests ofscripts/series.py, which run inUNIT_JOBSworker processes (default 4), one test module per task, through unittest-parallel. The unit-test run fails when it leaves files in its temporary directory (scripts/tmp_leak_guard.py).- REUSE compliance runs in the REUSE workflow; the local
reuse-linthook inlefthook.ymlrunsreuse lintwhen REUSE 6.x is installed. python3 scripts/lint_mutable_defaults.py(alsomake lint-mutable-defaults): Pylint checks Python sources fordangerous-default-value(W0102), including defaults bound to identifiers that ruff B006 misses. The script'sPYLINT_VERSIONpins Pylint; it uses that exact version on PATH or fetches it withuvx.make filter-deps FILTER_DEPS_TREE=<FFmpeg tree>: scans filter source calls against configure declarations and conditional library link edges.- inside the series check: every patch with an upstream link has a record
in
upstream-contributions.jsonwith a matching state, and the table in this file equals the one generated from the records. The check does not ask the forge; thecheckeddate says when the states were read - apply on the pinned release, byte-identical regeneration, an FFmpeg build with the GPL components, Vulkan, NVENC, VAAPI and QSV (libvpl) enabled and the FATE tests that need no samples
- a coverage gate: every C file the series changes must appear as compiled
(
CCline) in the build log, so a file in a component the configuration leaves out fails the run instead of passing the warning gate unseen; included*_template.cfiles are not checked, and zero checked files fail - a warning gate: any compiler warning in a file the series changes fails
the run; warnings elsewhere in FFmpeg are counted in the summary. On a
tree that applies the series to another upstream commit, such as FFmpeg
master,
series.py warnings TREE LOG --base <commit>names that commit, so upstream changes are not counted as the series' own - a function-length gate (HISS-04): no patch makes a C function longer than
60 lines without a live exception in that patch's
.tomlsidecar. CI runs it on every push to main and every release run; on a non-draft pull request only whenscripts/series.py scopeselects ffmpeg work. Draft or out-of-scope pull requests skip it. It needs the series applied to an FFmpeg checkout, somake verify-allruns it only whenFFMPEG_TREEnames one and otherwise skips it with a notice. Run it before pushing a patch change, withmake verify-all FFMPEG_TREE=<applied tree>or the gate on its own,make lengths FFMPEG_TREE=<applied tree>
A nightly run applies the series onto FFmpeg master with
series.py apply TREE --master-forms https://code.ffmpeg.org/FFmpeg/FFmpeg.git.
It fetches each recorded master_form and applies that PR diff instead of
the pinned-release patch. A master form that conflicts only in
libavfilter/Makefile, where each conflict region adds lines after the same
base line and changes none, is merged keeping the lines of both sides
(UNION_MERGE_PATHS in scripts/series.py); the run names the file and the
hunk count on stderr and in the commit message. A conflict in any other file,
a deleted or mode-changed file, or a region that changes base lines still
reports the patch as a conflict, with its reason on stderr. A pull request
that carries several patches records
its master_form on the last of them; the earlier ones report in-master-form
and are included only if that form applies. A recorded upstream_commit
that is an ancestor of the tested master reports the patch as upstream without
applying it; a missing commit fails the run because its history cannot be
checked. In a shallow tree, a recorded upstream_commit that is present but
not an ancestor of the tested master also fails the run, because the shallow
boundary can hide its ancestry; reset the tree to the commit the run started
from, fetch the full history and rerun, because the run has already committed
the earlier patches.
A release_only patch is reported as release-only and not applied.
Other patches use the series form. The run reports drop candidates and
fails on any conflict or tool error. Applying without --master-forms,
including consumer and CI runs with --expect-base, uses only the
pinned-release patches and ignores these metadata keys.
A daily run (upstream.yml) reads every pull request in
upstream-contributions.json from code.ffmpeg.org and fails when its state,
title, base branch, merge instant or merge commit no longer matches the
record. Update the record, regenerate the table and bump checked.
consumers.yml applies the series on the pinned base, then the patch stacks
of vidiko/vmafx and vidiko/pelorus (ffmpeg-patches/series.txt on their
default branches) on top, with git am --3way as their builds do. It runs
on every pull request, on main and nightly, and fails when a stack no
longer applies, so a series change that breaks a consumer shows before a
release carries it. It applies only; the consumers build in their own
repositories.
A consumer patch reports handed-over only when a series patch's .toml
declares that consumer and its added lines contain every consumer added-line
run at the same file path, while the consumer's known --pin NAME=TAG does
not yet contain that series patch (--series-dir defaults to this repository).
The gate warns that the consumer must drop the patch on its next pin bump
and continues its stack; a missing pin, an expired handover, or incomplete
coverage still fails, and an unknown tag is a tool error.
When two linked filters share no pixel or sample format, libavfilter inserts
a converter named auto_<filter>_<n> without asking. On a hardware path
(for example the Vulkan and CUDA import of 0008) that converter is a silent
software round trip. FFmpeg 8.0 and later dump the negotiated graph, and
scripts/graph_check.py exits 1 when the dump contains such a converter:
ffmpeg <inputs> <filters> <outputs> \
-print_graphs_file graphs.json -print_graphs_format json
python3 scripts/graph_check.py graphs.json # 1 on auto_scale_0 ...
python3 scripts/graph_check.py graphs.json --allow aresampletests/test_graph_check.py runs it on two real dumps, one with an
auto_scale_0 and one without.
ADR-0002 lets a tone-map path
land only when its mean CIEDE2000 against vf_libplacebo stays at or below
2.3. scripts/tonemap_parity.py measures that. It runs one reference chain
and any number of candidate chains on the same clip, compares every 30th frame
in BT.709 / gamma 2.4 / D65, and reports the mean, 95th percentile and maximum
difference, the wall time and the peak VRAM above idle (from nvidia-smi;
"not measured" without it). It exits 1 when a candidate misses the bar or
FFmpeg refuses to run it:
python3 scripts/tonemap_parity.py --ffmpeg ffmpeg --clip tests/fixtures/dv5/dv5.mp4 \
--ref 'libplacebo=tonemapping=hable:colorspace=bt709:color_primaries=bt709:color_trc=bt709:range=tv:format=yuv420p' \
--cand 'ocl=format=p010le,hwupload,tonemap_opencl=tonemap=hable:format=nv12,hwdownload,format=nv12' \
--pre 'ocl=-init_hw_device opencl=ocl:2.0 -filter_hw_device ocl' --json parity.jsonocl:2.0 is OpenCL platform 2, device 0;
ffmpeg -v debug -init_hw_device opencl -f lavfi -i nullsrc=d=0.01 -f null -
lists them. On FFmpeg n9.0.2 without the series this example exits 1:
tonemap_opencl refuses the IPT-C2 frames of the clip, and the script records
that as a failed path with FFmpeg's exit status.
tests/fixtures/dv5/dv5.mp4 is a Dolby Vision profile 5 clip with reshape
curves whose values are known; tests/fixtures/dv5/dv5gen.c wrote it and says
how. The base layer holds arbitrary IPT content rather than a picture converted
with the inverse matrices: the reference is whatever vf_libplacebo makes of
the same RPUs, so no inverse is needed. tests/test_tonemap_parity.py checks
the colour difference against the published CIEDE2000 test pairs and the
gate's pass and fail decisions without FFmpeg.
The hosted runners have no GPU. The pinned-base job of series.yml runs the
GPU filters on Mesa software devices instead: lavapipe for Vulkan and rusticl
on llvmpipe for OpenCL. The step fails when FFmpeg opens another device, when
a device case is skipped, or when a GPU filter leaves the CPU filter's output:
| Tests | Filters | Bound |
|---|---|---|
tests/test_hqdn3d_vulkan.py, tests/test_hqdn3d_opencl.py |
hqdn3d_vulkan, hqdn3d_opencl |
the samples of hqdn3d (ADR-0004) |
tests/test_tonemap_vulkan.py, tests/test_tonemap_opencl.py |
tonemap_vulkan, tonemap_opencl (0015, 0017, 0019, 0021, 0034) |
one 8-bit code value of tonemap=bt2408_hable, with and without peak detection; a software conversion after tonemap_opencl keeps its output matrix (0015) |
Each test file also holds a planted wrong case that the comparison must refuse.
Two gaps remain:
hqdn3d_cuda(tests/test_hqdn3d_cuda.py) needs an NVIDIA device, and CUDA has no software device, so CI does not run it. It runs where an NVIDIA GPU is present, withCUDA_FFMPEGandCUDA_DEVICEset.- The Metal (VideoToolbox) filters are built and checked for warnings on the macOS job, but their output is not compared with the CPU filters until an Apple host can run the parity tests.
See CONTRIBUTING.md for the development workflow, coding standards (HISS-21, NASA JPL Power of 10), and local verification instructions.
Check the Actions pages for Series, Consumers, FFmpeg Master, Upstream Drift, Release, and Scanners.
What support funds.
- Cloud test time on an NVIDIA device for the hqdn3d_cuda parity test, which hosted runners cannot run.
- Cloud test time on an Apple host to compare the Metal (VideoToolbox) filters with the CPU filters.
Sponsor on GitHub Sponsors, any amount; no support or priority is sold. Open Collective: pending.
A tag vX.Y.Z publishes a release; vX.Y.Z-rc.N publishes a prerelease.
release.yml first runs the full gate on the tagged commit, then
release-build.yml builds and signs these files:
ffmpeg-patches-<tag>.tar.gz:make distoutput, the series as committed, withscripts/series.py; the same commit always gives the same bytesffmpeg-patches-<tag>.spdx.json: SPDX SBOM of the tarballffmpeg-patches-<tag>.provenance.sigstore.json: SLSA build provenance, signed by the reusable workflow's identitySHA256SUMSandSHA256SUMS.sigstore.json: checksums, signed keyless with cosign
The release notes list the base and every patch with its upstream state, and show the verify commands. A consumer pins the tag and the tarball's sha256.
Versions follow SemVer and start below 1.0.0:
v0.MINOR.PATCHwhile vmafx and Pelorus adopt the series: MINOR moves when the FFmpeg base moves or a patch is added or dropped, PATCH for metadata or toolingv1.0.0once both consume it; from then on MAJOR moves with the FFmpeg base (consumers rebase their own patches), MINOR when a patch is added or dropped, PATCH for metadata or tooling
Pull requests on the FFmpeg forge that came out of this series and its consumers, and those of other authors that the series backports. A row without a series patch is a change the series does not carry.
| Pull request | Target | State | Change | Series patch |
|---|---|---|---|---|
| 24045 | master |
merged 2026-08-07 (63d0237033cc), in no release yet |
avutil/hwcontext_vulkan: Query export support with the real image flags | 0035 |
| 24835 | master |
merged 2026-10-19 (fd9a8f25a07b), in no release yet |
avfilter/vf_tonemap_opencl: zero the peak detection buffer | 0016 |
| 24970 | master |
open | avutil/vulkan: don't release frames to VK_QUEUE_FAMILY_IGNORED | 0001 |
| 24973 | master |
open | avfilter/vf_libvmaf: fix error paths (frame leak, frame count, uninitialized score, CUDA context) | 0042 |
| 24974 | master |
merged 2026-10-20 (2a8c6d30b934), in no release yet |
avcodec/av1dec: remove the coding bias from exported chroma grain params | none |
| 24975 | release/9.0 |
merged 2026-10-12 (7e93014c5bbb), in no release yet |
[release/9.0] hwcontext_vulkan: only originate host image layout transitions from copyable layouts | none |
| 24977 | master |
open | avcodec/vaapi_encode_h265: enable cu_qp_delta for ROI in CQP mode | none |
| 24978 | master |
open | avfilter/vf_libvmaf: add max pool method, reject unknown ones | none |
| 24993 | master |
closed | avcodec/nvenc: keep hevc_nvenc user data SEI within the picture limit | none |
| 24994 | master |
merged 2026-10-24 (96b7f8281a5f), in no release yet |
avcodec/nvenc: drop hevc_nvenc SEI above a fixed size | 0003 |
| 25053 | master |
open | hwcontext_vulkan: import a frame again when the CUDA context changes | 0008 |
| 25060 | release/9.0 |
merged 2026-10-14 (669f5ab083c7), in no release yet |
[release/9.0] vulkan: de-phase queue rotation and pin video pools to a single queue | 0007 |
| 25109 | master |
open | avutil/hwcontext_vaapi: accept GR1616 for P010/P012 DRM import | 0004 |
| 25110 | master |
closed | avutil/hwcontext_vulkan: wait on the CPU before RADV DRM mapping | 0006 |
| 25111 | master |
closed | Fix GCC 14 and 16 warnings in libavcodec, libavfilter, libavformat and tests | 0002 |
| 25112 | master |
merged 2026-10-16 (30b16e57ff3d), in no release yet |
ffbuild/library.mak: add the devprogs target | none |
| 25189 | master |
merged 2026-10-18 (ffb15c94c286), in no release yet |
avfilter/Makefile: link cuda/load_helper.o into three CUDA filters | none |
| 25468 | master |
merged 2026-10-27 (fa4daf630eb5), in no release yet |
avcodec/rv60dec: validate angular prediction buffer bounds | none |
| 25469 | master |
open | swresample/tests/swresample: allocate sample buffers and test indices | none |
| 25470 | master |
open | avcodec/tests: give large test buffers static storage | none |
| 25471 | master |
open | tools/ismindex: allocate output paths and report manifest errors | none |
| 25473 | master |
open | avfilter/vf_find_rect: assert the mipmap search pass bounds | none |
| 25474 | master |
merged 2026-11-15 (afa6f9089798), in no release yet |
avfilter: fix GCC 14 and 16 warnings in vf_median, af_firequalizer and af_afftfilt | none |
| 25475 | master |
open | avformat: fix GCC 14 and 16 -Wformat-truncation warnings in dashenc, matroskaenc and smoothstreamingenc | none |
| 25476 | master |
open | avformat: fix GCC 14 and 16 warnings in nspdec and rtsp | none |
| 25477 | master |
closed | avcodec/ffv1enc: move float remap scratch off the stack | none |
| 25478 | master |
merged 2026-11-12 (25cc947f444f), in no release yet |
avcodec/aac: fix GCC 14 and 16 -Wstringop-overflow warnings in aacenc and aacsbr | none |
| 25479 | master |
open | avcodec: fix GCC 14 and 16 warnings in a64multienc, h264dec, vlc and wmadec | none |
| 25480 | master |
open | avcodec/vvc: fix GCC 14 and 16 -Wstack-usage warnings in scaled prediction and checkasm | none |
| 25481 | master |
open | tests/checkasm: move large scratch buffers to the heap | none |
| 25483 | master |
merged 2026-11-02 (f675c507e20a), in no release yet |
avcodec/adpcm: fix GCC 14 and 16 unused warnings in single-decoder builds | none |
| 25533 | master |
open | checkasm/snowdsp: Include intmath before public headers | 0036 |
| 25534 | master |
open | avcodec/aom_film_grain: Assume the predicted luma point bound | 0037 |
| 25535 | master |
merged 2026-11-07 (0706d0ab1fad), in no release yet |
avcodec/vvc/intra_template: bound reference corner extension | 0038 |
| 25536 | master |
open | avcodec/wmalosslessdec: Clear subframe flags as an array | 0039 |
| 25708 | master |
open | avfilter/vf_libvmaf: accept more planar CUDA formats and copy all planes | 0040, 0041 |
| 25867 | master |
open | avfilter/vf_zscale: keep the light levels when linearising | 0014 |
| 25875 | master |
merged 2026-11-24 (e5b51e8b609e), in no release yet |
avcodec: add a qpfile option to libaom-av1, libsvtav1 and libx264 | 0043 |
| 25879 | master |
open | avfilter/vf_hqdn3d_vulkan: add a Vulkan hqdn3d filter | 0023 |
| 25885 | master |
open | avfilter/vf_tonemap: add the bt2408_hable tone map | 0012, 0013 |
State read from the FFmpeg forge on 2026-11-24.
A pull request against a release branch is a backport. It reaches a pinned base with the first release cut from that branch after the merge.
The same facts are in
upstream-contributions.json, one object
per pull request, for other pages to read. Its patch field is a string of
patch filenames separated by a comma and a space, or an empty string when
the series carries none. Every named patch must link to that pull request
and match its state.
The table lists all their series numbers and is generated from that file:
edit the file, then run python3 scripts/series.py contributions --write.
The pre-commit hook also regenerates and stages README.md whenever
upstream-contributions.json is staged.
Run python3 scripts/upstream_drift.py to compare recorded fields and
master_form commits with the FFmpeg forge. Add --fix to update changed
fields, set the checked date to today in UTC and regenerate the table.
--fix also moves the status of each linked patch sidecar to the repaired
state (submitted, merged with upstream_commit, rejected) and drops a
master_form that the new status no longer allows.
The inserted upstream_commit is the forge's merge commit, which is the
master commit only when the PR targets master. For a release-targeted PR,
replace it by hand with the master commit, or use release_only without
upstream_commit if no single master form exists.
Unchanged files keep their bytes and checked date. The README table is checked
even when the forge records match; --fix repairs a stale table without changing
the checked date. Concurrent edits detected before writing abort the repair
without changing any files. A merged or closed
covered_by pull request still needs human review before dropping its patch;
--fix reports it and exits 1. Tool errors exit 2; if --fix writes its
repairs but cannot remove the sibling manifest lock, it prints the fixed:
lines, reports the leftover: lock on standard error and exits 3.
The daily upstream workflow runs --fix with read-only repository permissions.
Changes appear in its job summary and the upstream-drift artifact as
upstream-drift.patch; the job fails whenever changes need review or drift
remains. Apply the downloaded patch with git apply upstream-drift.patch,
review it and submit the update through the usual pull request process.
Each contribution record in upstream-contributions.json may also carry two
optional lists that do not change the README table:
fixes_issues (sorted positive upstream issue numbers named after Fixes,
Closes or Refs in the pull body) and related (sorted objects with
number, kind one of pull or issue, author, reason one of
same-files, same-patch-id or same-subject, state, and seen
YYYY-MM-DD date). fixes_issues only grows: fill stores the union of the
stored numbers and the numbers in the pull body. Fill refreshes related rows
in place: a freshly found row replaces the stored row with the same number and
keeps only that row's first seen date, so a pull that changes from open to
merged updates its state (_fill_entry and merge_related in
scripts/upstream_links_manifest.py). Run python3 scripts/upstream_links.py fill (--dry-run
to preview without writing) to populate both fields for open and merged
manifest records from the forge. Fill and check send GET requests only, post
nothing and need no credentials. Live matching checks shared files and subjects;
same-patch-id is not checked live, and forge-supplied patch IDs are ignored.
The schema retains that reason for separately supplied evidence. Repeat fill --pull N to narrow a fill to named open or merged manifest rows
(_fill_targets in scripts/upstream_links_manifest.py), for example
python3 scripts/upstream_links.py fill --dry-run --pull 24970 --pull 24973.
Candidate pulls are scanned once per run from the later of the earliest scoped
opening and UTC midnight 14 days before the run date
(DEFAULT_FILL_MAX_AGE_DAYS); each pull's changed files are fetched at most
once. For every own pull opened
before this boundary, fill prints N: candidates updated before DATE not read (fill age limit). This includes old open candidates that could still overlap;
the line reports incomplete history, and the manifest makes no claim that
those candidates were checked. Widen the history with fill --max-age-days 30
(accepted range: 1 through 365 days). The candidate list fails with exit 2 and
writes nothing only when its 20th page ends without completion evidence: no
empty page, no Link header with relations but no next, no reached
X-Total-Count and no update older than the window (read_candidate_pulls in
scripts/upstream_links_forge.py, _listing_complete in
scripts/upstream_links_parse.py); shorten the window to retry. Run
python3 scripts/upstream_links.py check (each check --pull N adds targets via
_check_targets in scripts/upstream_links.py for any open pull not yet in
the manifest) to list newly discovered potential overlaps;
it exits 1 when at least one unrecorded related pull by another author is open
or merged after the own pull was opened, and the daily upstream.yml job runs
this check alongside upstream_drift.py. By default, check scans updates
since the manifest's checked date minus 7 days; check --since YYYY-MM-DD
overrides that window for a catch-up run. Recorded related rows do not trigger
candidate file reads. A candidate recorded for one own pull can still need
files for another. Same-author candidates, closed unmerged candidates and
candidates merged at or before the own pull opened are skipped before file
reads; candidates updated before an own pull opened are also skipped. Older
open candidates remain eligible when their updates fall inside the run window
and at or after that own opening. Every remaining candidate can
match files even when its subject differs. Existing related
records are retained; skipped candidates produce no new records.
When a candidate's file listing is incomplete at the 1000-name or 20-page
limit without a proven shared file, fill --dry-run, fill and check print
its pull number, the number of files read and same-files undecided; it is
not recorded as a relation, and check exits 1 for the undecided comparison.
A proven shared file in a partial prefix remains a relation, with an explicit
incomplete-files diagnostic. Same-files matching remains a broad signal.
File and candidate pagination stops on an empty page, a server Link header
with relations but no next relation, or a reached X-Total-Count. Each Link
entry's rel parameter is read independently of parameter order, case and
quoting, with space-separated relation values. Only the exact next relation
continues; unknown relations still prove completion. An entry without rel
supplies no relation evidence. A short nonempty page alone never proves
completion; the next page is read within the 20-page budget.
At exactly the name cap, an available extra page is read without retaining more
names: empty proves completion and more names prove overflow. If all file pages
are used without completion evidence, external candidates remain undecided and
own pull listings fail with exit 2.
Each run pauses 0.5 seconds before every request, including the first, and
retains the 30-second timeout of each blocking network operation
(REQUEST_TIMEOUT). A first fill costs N + P + F
requests for N own pulls, P list pages and F total fetched file pages
across distinct own and eligible candidate pulls (with one file page per
pull, the measured two-pull, 12-page window needs at most 519 requests and
259.5 seconds of pauses plus network time, before author and memo savings).
RequestBudget.__call__ in scripts/upstream_links_forge.py admits a request
only while more than REQUEST_TIMEOUT plus the 0.5-second pause (30.5 seconds)
of the scan budget remains. Before request 519 the scan has paused 518 times
(259 seconds), so 1510.5 seconds remain (1800 minus the 30.5-second reserve
minus 259) for the network and local work of the 518 earlier requests, about
2.9 seconds each. At 25 ms per request, all 519 requests are admitted, and the
window still exits 2 when the earlier requests average more than about 2.9
seconds; narrow a fill with
fill --pull N (_fill_targets in scripts/upstream_links_manifest.py), or
narrow a check's candidate window with check --since YYYY-MM-DD
(check_window in scripts/upstream_links.py), or add check targets with
check --pull N (_check_targets in scripts/upstream_links.py).
Both commands derive their request cap as
N + 20 + (N + 1000) * 20 from the own-pull count, 20 list pages, 1000
candidate rows and 20 file pages per pull. Before reading files, a progress
line gives the candidate count, expected requests assuming one file page per
pull and a file-page upper bound.
The monotonic SCAN_BUDGET_SECONDS budget is 1800 seconds for network waits
in either command; detected exhaustion prints incomplete scan and exits 2
before publishing.
That 1800-second budget (1769.5 usable seconds after the 30.5-second reserve)
is sized from the 1000-candidate cap: for N open targets in
upstream-contributions.json, a cap-sized scan makes at most N + 20
pre-plan requests and N + 1000 single-page file listings. At the pace
measured in one scheduled upstream.yml run on 2026-11-24 (about 3.6 seconds
per pre-plan request and 1.08 seconds per file listing, 0.5-second pacing
included), the 23 open targets of that run need 1259.64 seconds, or
1511.57 seconds with a 1.2 headroom factor.
test_scan_budget_covers_candidate_cap_at_measured_ci_pace in
tests/test_workflow_actions.py pins this bound and turns red at 69 open
targets.
Admission reserves pacing and a full network-operation
timeout, and elapsed time is checked again after pacing and each fetch.
A single read-only daemon worker performs
each fetch; waiting ends at the remaining scan budget even if the socket keeps
making progress. Fill checks the same deadline during preparation and
immediately before atomic replacement; detected expiry refuses publication with
exit 2 and attempts staging-file and lock cleanup with the error reporting
described below.
Local CPU work and local file operations are not interrupted, so the budget is
not a hard whole-run time limit. On detected expiry no further fetch is
admitted; the process can exit while the outstanding read finishes. Overlaps run
in a separate workflow job, independent of drift, with a timeout of twice that
budget (60 minutes); a workflow test pins this relationship.
The maximum 4096 own pulls admit 106036 requests:
53018 seconds of pacing, or 3234098 seconds including one 30-second blocking
operation per request, so the request cap alone cannot bound job time.
A request above the cap exits 2 with its
count, cap, window start, candidate count and narrowing option. A failure
before publication leaves the manifest unchanged and reports the original error
together with every failed staging-file or lock cleanup path (exit 2). After
replacement, cleanup failure exits 3 with
published ...; cleanup incomplete; exit 3 and one leftover: line per failed
cleanup path; the published manifest stays in place.
Status 3 is reserved for completed manifest or --fix writes with leftover
cleanup files; clean fills and repairs
exit 0.
Check exits 0 without overlaps, 1 for overlaps or undecided file comparisons,
and both commands exit 2 for read, input or incomplete-scan errors. Check writes
nothing and cannot reach status 3. Treat status 3 as a visible failure requiring
cleanup review before another writing fill or --fix repair; do not roll back
the published bytes.
Fill keeps its sibling temporary file private until content is written and
synced, then copies only the manifest's user/group/other read, write and execute
bits before atomic replacement. Set-id and sticky bits are not copied; a mode
change failure aborts before publication with exit 2.
Age and incomplete-file notices print independently of record changes on both
dry-run and writing paths. When records are unchanged, fill preserves the exact
manifest bytes and takes no lock. Fill refuses content changed since the initial
read; writing fills and upstream_drift.py --fix share an exclusive sibling
lock. A leftover lock blocks writing fills and --fix repairs with its path
(relative to the working directory when
--root is relative) and a stale-lock rule: confirm no fill and no --fix
repair is running for that
manifest, then review and
remove the lock before retrying. No automatic lock
removal occurs. Other writers must coordinate
with that lock to exclude edits during the final compare-and-replace step.
Missing or malformed decision fields, responses over 16 MiB, titles or paths
over 4096 characters, names over 256 characters, bodies over 256 Ki characters,
inline file lists over 2000 names, duplicate JSON keys, and JSON objects over
1024 keys fail with exit 2. Related authors use the shared
MAX_RELATED_AUTHOR_CHARS limit of 256; only nonblank printable text is
accepted, excluding every control character and line separator before
diagnostics. Issue parsing permits
at most 64 clauses and 1024 references, including repeats; excess is an error.
Each closing clause starts a comma-, and- or or-separated item list.
Only whole #N items and exact configured repository issue URLs are local.
Repository-prefixed hashes (including the configured repository) and foreign
issue URLs are ignored and counted in one line per pull. Prose, unhashed
numbers, versions and hashes glued to words end the list.
Shorten a fill with fill --max-age-days N (fill_window in
scripts/upstream_links_manifest.py), select rows with fill --pull N
(_fill_targets in scripts/upstream_links_manifest.py), narrow a check's
candidate window with check --since YYYY-MM-DD (check_window in
scripts/upstream_links.py), or add check targets with check --pull N
(_check_targets in scripts/upstream_links.py). The week-long margin revisits
recent updates
around the drift snapshot, which can advance independently of the link scan;
fill preserves that snapshot date. The fill age limit does not apply to check;
its effective window remains the later of the earliest scoped opening and
the checked date minus 7 days (or --since). Related seen dates record
proven links, not coverage of unread history.
The patches change FFmpeg's sources and keep FFmpeg's LGPL-2.1-or-later. The
tooling and documentation are EUPL-1.2. REUSE.toml records both.
Praetor manages this repository's declared governance policy. This managed block records adoption state; it is not a verification certificate.
Verification: make verify-all runs the repository's configured
verification cascade.
HISS Audit: praetorctl audit enforces policy, generated-surface
integrity, and the debt ratchet.
Context Sync: praetorctl compile-context --verify verifies every
generated agent context against AGENTS.md.
Debt Baseline: .standards-baseline.json anchors the debt ratchet at
1 recorded infraction; audit forbids growth.