1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-11-23 21:54:53 +02:00
Commit Graph

2468 Commits

Author SHA1 Message Date
Gyan Doshi
9895c4222c doc/filters: correct psnr option name (#20199)
Correct doc entry from stats_add_max to output_max
2025-08-10 11:02:22 +05:30
Vittorio Palmisano
13ce36fef9 libavfilter: Whisper audio filter
It adds a new audio filter for running audio transcriptions with the whisper model.
Documentation and examples are included into the patch.
2025-08-08 21:59:56 +02:00
Lynne
d3288013ab vf_libplacebo: add support for specifying a LUT for the input
This makes it possible to apply Adobe .cube files to inputs.
2025-08-05 23:51:13 +09:00
Timo Rothenpieler
262d41c804 all: fix typos found by codespell 2025-08-03 13:48:47 +02:00
Niklas Haas
545f721b44 avfilter/vf_colordetect: add new color range detection filter
This filter can detect various properties about the image, including
whether or not there are out-of-range values, or whether the input appears
to use straight or premultiplied alpha.

Of course, these can only be heuristics, with "undetermined" as the base
case. While we can definitely prove the existence of full range or
straight alpha colors, we can never infer the opposite.
2025-07-21 18:10:25 +02:00
Jorge Estrada
ad0a44028d avfilter: add pad_cuda filter
This patch adds the pad_cuda video filter. A filter similar to the existing pad filter but accelerated by CUDA.

The filter shares the same options as the software pad filter.

Example usage:
ffmpeg -hwaccel cuda -hwaccel_output_format cuda -i input.mp4 -vf "pad_cuda=w=iw+100:h=ih+100:x=-1:y=-1:color=red" out.mp4

Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2025-07-04 01:32:27 +02:00
Niklas Haas
7039a37e35 avfilter/vf_libplacebo: add reset_sar option
This was requested by users of `vf_libplacebo`, to mirror the existing
option on the other `vf_scale_*` family of filters. While we have
`vf_normalize`, it was not as useful in the event that the content
stretching was actually desired.

Bridges an important usability gap between `vf_scale` and `vf_libplacebo`
that made mixing and matching the filters needlessly difficult.
2025-06-20 15:13:25 +02:00
Clément Péron
90424a4475 various: fix typos
usefull -> useful
seperately -> separately
reciever -> receiver

Signed-off-by: Clément Péron <peron.clem@gmail.com>
2025-06-15 21:00:38 +05:30
Niklas Haas
0894cfb168 avfilter/blackdetect_vulkan: add hw accelerated blackdetect filter
Like vf_blackdetect but better, faster, stronger, harder.

Signed-off-by: Niklas Haas <git@haasn.dev>
Sponsored-by: nxtedition
2025-05-28 12:21:27 +02:00
Niklas Haas
7e783fac5b avfilter/vf_blackdetect: add alpha option
Check the alpha plane for (almost) transparent frames, instead of checking
the luma channel for almost black frames.

Signed-off-by: Niklas Haas <git@haasn.dev>
Sponsored-by: nxtedition
2025-05-28 12:21:27 +02:00
Niklas Haas
559317cc13 avfilter/vf_libplacebo: add shader_cache option
Useful to speed up shader compilation. May significantly lower startup
times, in particular with large or complex shaders.

Sponsored-by: nxtedition
2025-05-23 14:05:16 +02:00
Niklas Haas
4f623b4c59 avfilter/vf_libplacebo: implement rotation option
Flipping can already be accomplished by setting the crop_w/h expressions to
their negative values, so together these options can implement any of the
common frame orientations.
2025-05-23 14:02:45 +02:00
Michael Niedermayer
8c920c4c39 Remove libpostproc
Libpostproc will be available as source plugin at
https://github.com/michaelni/FFmpeg/tree/sourceplugin-libpostproc
OR
https://github.com/michaelni/libpostproc

whatever turns out more convenient to maintain

For the upcoming 8.0 release, libpostproc will be included, so as not to
cause delays or inconveniences

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2025-05-07 15:35:47 +02:00
Niklas Haas
853e66a072 doc/filters: fix "ewa_lanczos" filter description 2025-04-20 14:32:18 +02:00
Zhao Zhili
6995372ea2 doc/filters: Fix video size of mptestsrc
Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
2025-04-16 19:33:55 +08:00
Danil Iashchenko
1015ea2ba1 doc/filters: add thumbnail_cuda entry
Also update thumbnail_cuda filter description.
2025-03-31 18:48:01 +05:30
Danil Iashchenko
a1c6ca1683 doc/filters: Shift CUDA-based filters to own section. 2025-03-17 12:38:51 +05:30
Niklas Haas
5944c4b20a avfilter/vf_libplacebo: remove deprecated options
These were removed upstream and no longer have had any effect for
a while now.

Signed-off-by: Niklas Haas <git@haasn.dev>
2025-02-27 18:56:19 +01:00
Niklas Haas
27814dc3b6 avfilter/libplacebo: add option for outputting separate fields
cf. the other deinterlacing-aware filters.
2025-02-27 18:55:33 +01:00
Niklas Haas
794cba812e avfilter/libplacebo: add deinterlacing options
These were introduced in libplacebo API version 220. We actually already
map the field by default, but deinterlacing was never enabled unless the user
explicitly forced it using extra_ops.
2025-02-27 18:55:33 +01:00
Niklas Haas
cd81f08491 avfilter/libplacebo: use a transparent default fillcolor
This will leave the background transparent when the target format
contains an alpha channel, without affecting the behavior on formats
without one.
2025-02-19 18:33:21 +01:00
Niklas Haas
4dc2ae69e7 avfilter/interlace_vulkan: add interlace_vulkan filter
This is a Vulkan-accelerated version of the existing interlace filter.
2025-02-17 17:16:25 +01:00
Gyan Doshi
7ee4936e0a avfilter/vpp_amf: add option reset_sar
4b77a0a681 added a new consumer of ff_scale_adjust_dimensions
which was recently modified to allow for square pixel output.

This commit extends the new option to vpp_amf, and unbreaks the building
of vf_amf_common.c
2025-02-10 19:59:26 +05:30
Gyan Doshi
a28dc06869 avfilter/scale*: add option reset_sar
For anamorphic videos, enabling this option leads to adjustment of
output dimensions to obtain square pixels when the user requests
proportional scaling through either of the w/h expressions or
force_original_aspect_ratio.

Output SAR is always reset to 1.

Option added to scale, scale_cuda, scale_npp & scale_vaapi.

libplacebo already has a similar option with different semantics,
scale_vt and scale_vulkan don't implement force_oar, so for these
three filters, I've made minimal changes needed to not break building
or change output.
2025-02-10 16:25:23 +05:30
Evgeny Pavlov
1f94cc4588 doc/filters: Add documentation for AMF filters
Signed-off-by: Evgeny Pavlov <lucenticus@gmail.com>
2025-02-04 00:14:14 +01:00
Gyan Doshi
221816456a doc/filters: fix typo in format filter
The inline example for option color_ranges used 'color_spaces'

Fixes #11441
2025-01-31 23:15:40 +05:30
Gyan Doshi
959b799c8d avfilter/setpts: add option strip_fps to decide framerate handling
In f121d95, the outlink framerate was unconditionally unset.
This breaks/bloats outputs from CFR muxers unless the user explicitly
sets a sane framerate. And the most common invocation for setpts seen in
workflows, our docs and across the web is `PTS-STARTPTS` or others of the
general form `PTS+constant` which preserves the input framerate.

Default value is false, which restores old behaviour.

Fixes #11428
2025-01-27 15:40:09 +05:30
Niklas Haas
b7a2333357 avfilter/vf_scale: add colorspace and transfer property options
In the long run, it would be ideal if we could add these to the avfilter
negotiation as well, but for now, this is a good start.
2024-12-23 12:33:43 +01:00
Niklas Haas
45f0a7ad33 swscale: add ICC intent enum and option
This setting can be used to infuence the type of tone and gamut mapping used
internally when color space conversions are required. As discussed at VDD'24,
the default was set to relative colorimetric clipping, which is approximately
associative, surjective and idempotent. As such, it roundtrips well, although
it is strictly speaking not associative on out-of-gamut colors.
2024-12-23 12:33:43 +01:00
James Almer
d2c90abab7 doc/filters: add an entry for vf_lcevc
Signed-off-by: James Almer <jamrial@gmail.com>
2024-12-02 12:53:54 -03:00
Anton Khirnov
299d9115d4 lavfi/f_select: allow selection based on view ID
Can be used together with the split filter to decompose multiview video
into individual views.
2024-09-23 17:11:40 +02:00
Christian Helmrich
865cd3c056 avfilter: add XPSNR filter
Add XPSNR video filter
Register new filter xpsnr.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-09-08 17:51:37 +02:00
Gyan Doshi
3d0d0f68d5 doc/filters: update uspp availability status
The filter was disabled in 95054bfa48 and re-enabled in 771c27119d
2024-09-05 15:47:14 +05:30
Niklas Haas
15a67c0947 avfilter/vf_scale: add in/out_chroma_loc
Currently, this just functions as a more principled and user-friendly
replacement for the (undocumented and hard to use) *_chr_pos fields.

However, the goal is to automatically infer these values from the input
frames' chroma location, and deprecate the manual use of *_chr_pos
altogether. (Indeed, my plans for an swscale replacement will most
likely also end up limiting the set of legal chroma locations to those
permissible by AVFrame properties)
2024-08-16 11:43:37 +02:00
Niklas Haas
201f1cba15 avfilter/vf_setparams: allow setting chroma location
Shockingly, there isn't currently _any_ filter for overriding this.
2024-08-16 11:43:37 +02:00
ha7sh17
172da370e7 doc/filters: fix outpad labels in libvmaf_cuda example 2024-07-22 13:00:04 +05:30
Stefano Sabatini
9c357324f0 doc/filters/perlin: specify default values 2024-07-06 14:14:02 +02:00
Gyan Doshi
03175b587c doc/filter: fix grammar in tiltandshift filter 2024-07-04 15:21:17 +05:30
Stefano Sabatini
3764b8ecdb lavfi: add Perlin noise generator 2024-07-01 22:31:02 +02:00
Stefano Sabatini
77ad449911 doc/filters/curves: fix typos 2024-06-03 11:24:33 +02:00
Stefano Sabatini
17a759cce1 doc/filters/tiltandshift: apply typo fixes, add introductory description 2024-06-03 11:07:27 +02:00
Andrea Mastroberti
90ce54804a avfilter/smartblur: Added alpha layer support
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-05-19 22:12:53 +02:00
PoorvaGaikar
8b6e66d0f0 avfilter/f_select.c: add support for iw and ih variables
Fixes ticket #10509.

Signed-off-by: Marton Balint <cus@passwd.hu>
2024-05-08 21:33:32 +02:00
Niklas Haas
df868bae23 doc/filters: mention scale2ref in replacement example
So ctrl+f "scale2ref" finds it.
2024-05-04 13:15:15 +02:00
Niklas Haas
8bf0a9c2ca doc/filters: move scale=ref_* to correct sectton
This was accidentally filed under scale_npp, instead of scale. (Why is
this entire section basically duplicated anyway?)
2024-05-04 13:15:11 +02:00
Niklas Haas
95568c4e31 avfilter/scale2ref: deprecate in favor of scale=rw:rh
And remove it from the documentation.
2024-05-03 14:23:23 +02:00
Niklas Haas
bb80445813 avfilter/vf_scale: add optional "ref" input
This is automatically enabled if the width/height expressions reference
any ref_* variable. This will ultimately serve as a more principled
replacement for the fundamentally broken scale2ref.

See-Also: https://trac.ffmpeg.org/ticket/10795
2024-05-03 14:23:23 +02:00
Niklas Haas
e82a3997cd avfilter/vf_scale: switch to FFFrameSync
Preliminary commit, in anticipation of adding support for multiple
inputs (with proper synchronization and activate() callback).
2024-05-03 14:23:23 +02:00
Xinpeng Sun
35ae44c615 lavfi/tonemap_vaapi: Add support for HDR to HDR tone mapping
Usage example:
ffmpeg -y -hwaccel vaapi -hwaccel_output_format vaapi -i hdr.mp4 \
-vf "tonemap_vaapi=display=7500 3000|34000 16000|13250 34500|15635 16450|500 10000000:extra_hw_frames=64" \
-c:v hevc_vaapi output.mp4

Signed-off-by: Xinpeng Sun <xinpeng.sun@intel.com>
Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
2024-04-18 14:43:07 +08:00
Haihao Xiang
3172a6722e lavfi/tonemap_vaapi: By default use bt709 for output frame
By default don't use the color properties from input frame as output
frame properties when performing HDR to SDR conversion

Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
2024-04-18 14:43:07 +08:00