Niklas Haas
098b338369
lavfi/vf_libplacebo: require v5.278 for importing
...
Importing Vulkan device on older versions no longer works due to the
lavu vulkan API changes (specifically, the switch to planar textures by
default). Additionally, importing on versions that don't suppirt
lock/unlock_queue is unsafe with the advent of the threaded vulkan
hwaccel. As a plus, saves us some annoying #ifdef boilerplate.
I will raise the minimum vf_libplacebo version globally on the next
stable release of libplacebo, and remove all of these checks.
2023-05-29 18:56:56 +02:00
Paul B Mahol
45fa85a777
avfilter/silenceremove_template: refactor detectors using common peaks code
2023-05-29 11:47:11 +02:00
Paul B Mahol
f02964aee1
avfilter/af_silenceremove: add standard deviation detector
...
Useful in cases audio samples DC offset is not ~0.0, where
other detectors will fail to detect silence.
2023-05-29 11:47:10 +02:00
Paul B Mahol
aa4acc111e
avfilter/af_silenceremove: use separate variable for size of cache
2023-05-29 11:47:07 +02:00
Paul B Mahol
364c03d9fe
avfilter/silenceremove_template: improve ptp detector
2023-05-29 11:47:06 +02:00
Michael Niedermayer
0c7a0514e3
avfilter/window_func: Use av_bessel_i0()
...
Old code needed about 6 times as long as new with defaults in afftfilt
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2023-05-29 00:55:52 +02:00
Michael Niedermayer
1e9c337e0f
avfilter/asrc_sinc: Use av_bessel_i0()
...
The new function is much more precise
For default beta it is slightly slower, but its speed is already at the
worst case in that comparison
while the replaced function becomes much slower for larger beta
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2023-05-29 00:55:52 +02:00
Lynne
160a415e22
lavfi: add nlmeans_vulkan filter
2023-05-29 00:42:01 +02:00
Lynne
88e2cca3db
tools/cl2c: change to tools/source2c and allow non-OpenCL source files
2023-05-29 00:42:00 +02:00
Lynne
7cfd7e4af4
lavfi: add color_vulkan filter
2023-05-29 00:42:00 +02:00
Lynne
09dc9193ea
lavfi: add bwdif_vulkan
2023-05-29 00:41:56 +02:00
Niklas Haas
b41ea8c6c3
avfilter/vf_libplacebo: bump max vk version
...
For two reasons:
1. We now create a vulkan 1.3 device
2. libplacebo master currently requires a vulkan 1.3 device
2023-05-29 00:41:55 +02:00
Niklas Haas
661db605db
avfilter/vf_libplacebo: forward queue locking primitives
...
For thread safety.
2023-05-29 00:41:55 +02:00
Lynne
f70f873272
transpose_vulkan: port for the rewrite
2023-05-29 00:41:54 +02:00
Lynne
d4b51b5085
scale_vulkan: port for the rewrite
2023-05-29 00:41:54 +02:00
Lynne
8e9ceb1efb
overlay_vulkan: port for the rewrite
2023-05-29 00:41:54 +02:00
Lynne
59f21c051d
gblur_vulkan: port for the rewrite
2023-05-29 00:41:53 +02:00
Lynne
d26cbae3e1
flip_vulkan: port for the rewrite
2023-05-29 00:41:53 +02:00
Lynne
125636608d
chromaber_vulkan: port for the rewrite
2023-05-29 00:41:52 +02:00
Lynne
40bf1d525e
blend_vulkan: port for the rewrite
2023-05-29 00:41:52 +02:00
Lynne
f29850e98f
avgblur_vulkan: port for the rewrite
2023-05-29 00:41:52 +02:00
Lynne
05ce6473ac
lavfi: add lavfi-only Vulkan infrastructure
2023-05-29 00:41:51 +02:00
Lynne
15de0af8f0
vulkan: allow alloc pNext in ff_vk_create_buf
2023-05-29 00:41:45 +02:00
Lynne
b5e333bba7
vulkan: add pNext argument to ff_vk_create_buf()
2023-05-29 00:41:43 +02:00
Paul B Mahol
62d4110a64
avfilter/af_silenceremove: add timestamp option
2023-05-28 12:23:14 +02:00
Paul B Mahol
b95d123097
avfilter/silenceremove_template: revert wrong change
2023-05-28 12:23:13 +02:00
Paul B Mahol
e53260c1f4
avfilter/af_silenceremove: add ptp detector
2023-05-28 12:23:11 +02:00
Paul B Mahol
e8e4863325
avfilter/af_silenceremove: fix the any/all confusion and change default
...
'any' stop mode is now correctly implemented for end trimming and is of limited usage.
Extend examples and other documentation of this filter.
2023-05-27 16:04:00 +02:00
Paul B Mahol
8d662adcc9
avfilter/af_silenceremove: speed-up filtering once start-trim is over
...
No point to call filter_start on samples that will pass them unchanged
once initial trimming stopped.
2023-05-27 11:18:02 +02:00
Paul B Mahol
965f99f904
avfilter/af_silenceremove: add timeline support
2023-05-27 11:18:00 +02:00
Paul B Mahol
7927a96e2b
avfilter/af_silenceremove: add commands support
2023-05-27 11:17:58 +02:00
Paul B Mahol
5a13b133f8
avfilter/af_silenceremove: add median silence detector
2023-05-27 00:34:37 +02:00
Paul B Mahol
68d0b881de
avfilter/silenceremove_template: fix peak detector
...
The implementation was not working correctly.
2023-05-27 00:34:35 +02:00
Paul B Mahol
29710dd7f2
avfilter/af_silenceremove: speed-up start-only trimming once trim is over
2023-05-26 10:13:37 +02:00
Paul B Mahol
f59d9514da
avfilter/silenceremove_template: skip silence start detection after start-only trimming is over
2023-05-26 10:13:37 +02:00
Paul B Mahol
2b5166addf
avfilter/af_silenceremove: add real peak detector
...
Rename old peak detector to more correct name one.
2023-05-26 10:13:37 +02:00
Paul B Mahol
3235de4883
avfilter/af_silenceremove: switch to activate
...
Do full rewrite, new code is much faster for typical filter usages.
Also previous code was hard to follow and basically very-hard to maintain.
2023-05-26 10:13:37 +02:00
Paul B Mahol
90fba27743
avfilter/trim: switch to activate
...
This also signals EOF to filter inlink so that unnecessary
extra processing that is immediately dropped by this filter
is not done any more.
2023-05-25 19:52:04 +02:00
Paul B Mahol
a1838c59bb
avfilter/af_astats: add abs_peak_count stat
2023-05-25 19:51:39 +02:00
Zhao Zhili
43ace8f2bc
avfilter/vf_subtitles: add wrap_unicode option
...
So CJK can be wrapped automatically.
Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
2023-05-25 11:31:54 +08:00
Niklas Haas
0bce5590c3
lavfi/vf_libplacebo: fix crop expr PTS calculation
...
mix->timestamps is expressed relative to the source timebase, which is
possibly a different timescale from `base_pts`. We can't mix-and-match
here. The only reason this worked in my previous testing was because I
was testing on a source file which had an exactly matching timebase.
Fix it by always using the exact PTS as tagged on the AVFrame.
2023-05-24 14:39:40 +02:00
Niklas Haas
d815584755
lavif/vf_libplacebo: move code (cosmetic)
...
To eliminate need for forward declaration
2023-05-23 15:06:18 +02:00
Niklas Haas
ee13414444
lavfi/vf_libplacebo: update settings after adding hooks
...
Failure to do so led to the update s->hooks never getting correctly
propagated to the render params.
2023-05-23 15:05:21 +02:00
Marvin Scholz
86b252ea9d
avfilter/vf_tpad: accept hardware frames in clone-only mode
...
When no drawing is to be performed, tpad can work fine with
hardware frames, so advertise this in the query_formats
callback and ensure the drawing context is never initialised
when just cloning frames.
Reviewed-by: Thilo Borgmann <thilo.borgmann@mail.de>
Reviewed-by: Niklas Haas <git@haasn.dev>
2023-05-22 18:41:22 +02:00
Marvin Scholz
fa7180b827
avfilter/vf_tpad: use enum for start/stop_mode
...
Reviewed-by: Thilo Borgmann <thilo.borgmann@mail.de>
Reviewed-by: Niklas Haas <git@haasn.dev>
2023-05-22 18:40:42 +02:00
Paul B Mahol
c37cf59c5b
avfilter/vf_xfade: send EOF to first input early
...
No point to consume 1st input frames any more after crossfade is over.
2023-05-22 17:13:31 +02:00
Niklas Haas
877ccaf776
lavfi/vf_libplacebo: don't intrude on pl_ namespace
...
No reason to use this prefix here.
2023-05-22 10:31:51 +02:00
Niklas Haas
21715ecff1
lavfi/vf_libplacebo: update peak detection options
...
Upstream peak detection lost one option and gained one option. Update
code and documentation as required.
2023-05-22 10:31:51 +02:00
Niklas Haas
643cf2ec46
lavfi/vf_libplacebo: update for new tone mapping API
...
This algorithm has once again been refactored, this time leading to a
dropping of the old `tone_mapping_mode` field, to be replaced by a
single tunable hybrid mode with configurable strength.
We can approximately map the old modes onto the new API for backwards
compatibility. Replace deprecated enums by their integer equivalents to
safely preserve this API until the next bump.
2023-05-22 10:31:50 +02:00
Niklas Haas
d637f20f05
lavfi/vf_libplacebo: switch to new gamut mapping API
...
Upstream deprecated the old ad-hoc, enum/intent-based gamut mapping API
and added a new API based on colorimetrically accurate gamut mapping
functions.
The relevant change for us is the addition of several new modes, as well
as deprecation of the old options. Update the documentation accordingly.
2023-05-22 10:31:50 +02:00