Commit Graph

118377 Commits

Author SHA1 Message Date
Zhao Zhili
69c79bb32a tests/fate-run: Fix pixdesc failure
-u and -q doesn't work together for diff on macOS.

Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-31 08:23:44 +01:00
Zhao Zhili
f3741f017b avcodec/mediacodecdec_common: Workaround MTK broken crop implementation
MediaTek SOC return broken crop info, e.g.,
width: int32(3840) height: int32(2160) crop: Rect(0, 0, 318, 238)

It will notify the right crop info with infoOutputFormatChanged, but
too late.

Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-31 08:23:44 +01:00
Zhao Zhili
05dfc5d97b avcodec/mediacodecenc: Extract configOBUs from AV1CodecConfigurationRecord
MediaCodec can generate AV1CodecConfigurationRecord, which shouldn't
be put into packet->data. Skip four bytes and extract configOBUs
if it exist.

Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-31 08:23:44 +01:00
Zhao Zhili
4538551b20 fftools/ffplay: use swapchain_colorspace_hint to get better HDR support
For example, the default surface configuration on macOS is:
VK_FORMAT_A2B10G10R10_UNORM_PACK32 + VK_COLOR_SPACE_PASS_THROUGH_EXT

With HDR10 content and swapchain_colorspace_hint, the surface
configuration updated to:
VK_FORMAT_A2B10G10R10_UNORM_PACK32 + VK_COLOR_SPACE_HDR10_ST2084_EXT

Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-31 08:23:43 +01:00
Paul B Mahol
9194248796 avfilter/ardftsrc_template: change from tukey to planck-taper window
Gives less artifacts.
2024-10-30 09:07:44 +01:00
Paul B Mahol
12afae0ac5 avutil/tx: fix signed integer overflow 2024-10-29 20:31:37 +01:00
Paul B Mahol
3e785c16c5 avutil/tx_template: remove invalid code, and fix min_len for bailey 2024-10-29 19:45:27 +01:00
Paul B Mahol
a164309cb4 avfilter/af_ardftsrc: check for eof early 2024-10-29 14:23:31 +01:00
Paul B Mahol
eb3ad9302b avfilter/vf_waveform: fix crash when graticule is shown 2024-10-29 09:14:28 +01:00
Paul B Mahol
a74760358e avfilter/surround_template: no need to use FFMIN3 2024-10-28 19:07:57 +01:00
Paul B Mahol
df485f8ede avfilter/surround_template: revert same scaling for forward and backward transform 2024-10-28 17:40:38 +01:00
Paul B Mahol
d2c7ed2fd0 avfilter/surround_template: reduce x/y center channel strength 2024-10-28 16:42:19 +01:00
Paul B Mahol
462283e8b8 avfilter/avf_showspatial: fix output for extreme panning 2024-10-28 15:51:29 +01:00
Paul B Mahol
676ed56e24 avfilter/avf_showspatial: remove scaling for transform 2024-10-28 09:18:31 +01:00
Paul B Mahol
6cdd6b5457 avfilter/surround_template: fix output for extreme panning 2024-10-28 09:15:29 +01:00
Paul B Mahol
c4941f7e60 avfilter/avf_showspatial: change output pixel format 2024-10-27 21:16:32 +01:00
Paul B Mahol
87af6f2d26 avfillter/af_surround: fix calculations 2024-10-27 21:16:30 +01:00
James Almer
53d5bb94f6 avutil/hwcontext_d3d11va: drop duplicate pixfmt entry
Added by accident in ca71b0b807b4d5588ec765976b8b18d3efde40fb.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 14:43:37 +02:00
Paul B Mahol
373147dd71 avfilter/surround_template: do normalization for power factors 2024-10-26 10:44:27 +02:00
James Almer
4b40c46ab3 libavutil/hwcontext_d3d11va: use the XV48 pixel format
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:06 +02:00
James Almer
c84b4800e1 libavutil/hwcontext_dxva2: use the XV48 pixel format
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:06 +02:00
James Almer
247af34ac0 avfilter/vsrc_testsrc: add support for XV48
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:06 +02:00
James Almer
d79e73e4be avformat/riff: map Y416 fourcc to RAWVIDEO decoder
As defined in https://learn.microsoft.com/en-us/windows/win32/medfound/10-bit-and-16-bit-yuv-video-formats#422-formats

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:06 +02:00
James Almer
da92f615b6 swscale/output: add XV48 output support
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:06 +02:00
James Almer
fdb4a8944e swscale/input: add XV48 input support
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:06 +02:00
James Almer
5eee9aef71 avutil/pixfmt: add XV48 pixel format
Much like XV30 and XV36 in d75c4693fe,
XV48 is added to support 16bit 4:4:4 as defined by Microsoft.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
James Almer
0ff5f0f722 libavutil/hwcontext_d3d11va: use the Y216 pixel format
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
James Almer
ebcb351da4 libavutil/hwcontext_dxva2: use the Y216 pixel format
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
James Almer
014e99eb2b avformat/riff: map Y210 and Y216 fourcc to RAWVIDEO decoder
As defined in https://learn.microsoft.com/en-us/windows/win32/medfound/10-bit-and-16-bit-yuv-video-formats#422-formats

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
Michael Niedermayer
c40bdd53ed avformat/mpegts: Initialize predefined_SLConfigDescriptor_seen
Fixes: use of uninitialized variable
Fixes: 368729566/clusterfuzz-testcase-minimized-ffmpeg_dem_MPEGTS_fuzzer-6044501804646400

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
Michael Niedermayer
36049cd54c avformat/mxfdec: Fix overflow in midpoint computation
Fixes: signed integer overflow: 4611686016549392399 + 9223372033098784800 cannot be represented in type 'long long'
Fixes: 368503277/clusterfuzz-testcase-minimized-ffmpeg_dem_MXF_fuzzer-5928227458056192

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
Michael Niedermayer
d30e00fcba swscale/output: used unsigned for bit accumulation
Fixes: Integer overflow
Fixes: 368725672/clusterfuzz-testcase-minimized-ffmpeg_SWS_fuzzer-5009093023563776

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
Michael Niedermayer
1509526901 swscale/rgb2rgb_template: Fix ff_rgb24toyv12_c() with odd height
Fixes: out of array access
Fixes: 368143798/clusterfuzz-testcase-minimized-ffmpeg_SWS_fuzzer-6475823425585152

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:05 +02:00
Dale Curtis
b00a93d711 avcodec/h2645: allocate film grain metadata dynamically
Film grain support adds a huge amount of overhead to the H264Context
structure for a feature that is rarely used. On low end devices or
pages that have lots of media this bloats memory usage rapidly.

This changes the static film grain metadata allocations to be dynamic
which reduces the H264Context size from 851808 bytes to 53444 bytes.

Bug: https://crbug.com/359358875
Signed-off-by: Dale Curtis <dalecurtis@chromium.org>
Signed-off-by: Niklas Haas <git@haasn.dev>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:28:04 +02:00
Michael Niedermayer
ac75e76e8d avcodec/ffv1: Implement new slice tiling
This fixes corner cases (requires version 4 or a spec update)

Fixes: Ticket5548

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:25:18 +02:00
Michael Niedermayer
f7299fba2a avcodec/rangecoder: only perform renorm check/loop for callers that need it
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:25:18 +02:00
Niklas Haas
7d8a5e3aee swscale: rename SwsContext to SwsInternal
And preserve the public SwsContext as separate name. The motivation here
is that I want to turn SwsContext into a public struct, while keeping the
internal implementation hidden. Additionally, I also want to be able to
use multiple internal implementations, e.g. for GPU devices.

This commit does not include any functional changes. For the most part, it is
a simple rename. The only complications arise from the public facing API
functions, which preserve their current type (and hence require an additional
unwrapping step internally), and the checkasm test framework, which directly
accesses SwsInternal.

For consistency, the affected functions that need to maintain a distionction
have generally been changed to refer to the SwsContext as *sws, and the
SwsInternal as *c.

In an upcoming commit, I will provide a backing definition for the public
SwsContext, and update `sws_internal()` to dereference the internal struct
instead of merely casting it.

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Niklas Haas <git@haasn.dev>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:25:17 +02:00
Soma Lucz
07239fb054 doc/ffmpeg: improve -disposition, -stats, and -progress documentation
-disposition:
Clarify the meaning of the default value, and how the '+' and '-'
prefixes work. Add more examples.

-stats:
Clarify that it appears as an "info"-level log.

-progress:
Add info about the "progress" key's value being "continue" or "end".
Add an example of logging to stdout.

Signed-off-by: Soma Lucz <luczsoma@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2024-10-26 09:18:34 +02:00
Paul B Mahol
8020860b1d avfilter/af_surround: add support for two more channels 2024-10-25 23:32:05 +02:00
Paul B Mahol
8ce6abcc05 avfilter/surround_template: simplify 2024-10-25 22:41:28 +02:00
Paul B Mahol
0b279cd954 avfilter/af_surround: misc fixes 2024-10-25 22:13:12 +02:00
Paul B Mahol
ea81ac4440 avfilter/af_ardftsrc: fix for possible integer overflow 2024-10-25 18:08:53 +02:00
Paul B Mahol
70079ea501 avfilter/af_surround: fix remaining spread_* issues 2024-10-25 09:14:42 +02:00
Paul B Mahol
035632ed89 avfilter/af_surround: extend minimal spread range 2024-10-24 23:10:49 +02:00
Paul B Mahol
a8d08dd250 avfilter/surround_template: remove useless operations 2024-10-24 22:26:19 +02:00
Paul B Mahol
4cc2f6f7af avfilter/af_aecho: add support for commands 2024-10-24 21:09:37 +02:00
Paul B Mahol
d2283bc734 avfilter/adynamicequalizer_template: use decramped qfactors 2024-10-24 20:38:27 +02:00
Paul B Mahol
30bc6eca9c avfilter/af_biquads: add decramp option 2024-10-24 20:38:27 +02:00
Paul B Mahol
de77159520 avfilter/vf_extractplanes: fix extracting of green component for some packed formats 2024-10-24 11:59:48 +02:00
Paul B Mahol
eea854b510 avfilter/vsrc_testsrc: fix <8 component depth rgb/bgr output for rgbtestsrc 2024-10-24 11:59:41 +02:00