1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-02 03:06:28 +02:00
Commit Graph

105769 Commits

Author SHA1 Message Date
Michael Niedermayer
36680078ca avformat/matroskadec: Check duration
Fixes: -nan is outside the range of representable values of type 'long'
Fixes: 44614/clusterfuzz-testcase-minimized-ffmpeg_dem_WEBM_DASH_MANIFEST_fuzzer-6216204841254912

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2022-02-25 22:23:03 +01:00
Michael Niedermayer
c900f2e42c tools/target_dem_fuzzer: Check fmt before dereferencing
Fixes: NULL pointer dereference
Fixes: 44884/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-4656748688965632

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2022-02-25 22:23:03 +01:00
Paul B Mahol
68bc9773cf avfilter/f_ebur128: set video outlink timebase and framerate 2022-02-25 18:15:26 +01:00
Paul B Mahol
e3f07185ed avfilter/f_ebur128: also set max peak for all channels in frame metadata 2022-02-25 18:15:26 +01:00
Paul B Mahol
e845c41c94 avfilter/af_dynaudnorm: cleanup gaussian_filter() function 2022-02-25 18:15:26 +01:00
Martin Storsjö
c523724c69 swscale: Take the destination range into account for yuv->rgb->yuv conversions
The range parameters need to be set up before calling
sws_init_context (which selects which fastpaths can be used;
this gets called by sws_getContext); solely passing them via
sws_setColorspaceDetails isn't enough.

This fixes producing full range YUV range output when doing
YUV->YUV conversions between different YUV color spaces.

Signed-off-by: Martin Storsjö <martin@martin.st>
2022-02-25 11:01:17 +02:00
Martin Storsjö
8a00caf309 Remove mentions of a nonexistent avversion.h
Signed-off-by: Martin Storsjö <martin@martin.st>
2022-02-25 11:01:17 +02:00
James Almer
1dddb930aa avcodec/libsvtav1: update some options and defaults
And bump the minimum required version to 0.9.0

Signed-off-by: James Almer <jamrial@gmail.com>
2022-02-24 20:36:53 -03:00
Paul B Mahol
353195fb38 avfilter/af_crystalizer: refactor code 2022-02-24 22:37:55 +01:00
Paul B Mahol
b9493e0cc0 avfilter/vf_tmidequalizer: check that frame is valid 2022-02-24 21:46:13 +01:00
Martin Storsjö
17ab836a5f libavcodec, libavdevice: Remove unnecessary includes of version.h
xvmc.h used FF_API_* macros before, but they were removed in
1c63aed232, leaving the include
unused.

The ones in android_camera.c and mediacodec_wrapper.c have been
added due to a misunderstanding, fixed in
c0bce367e4 and
13b77af2f0.

The one in mediacodec.c seems to never have been used at all.

Signed-off-by: Martin Storsjö <martin@martin.st>
2022-02-24 22:36:15 +02:00
Paul B Mahol
6f04b43c22 avfilter/vf_tpad: handle case when no frame was ever received 2022-02-24 21:28:23 +01:00
Paul B Mahol
3715f2f864 avfilter/vf_tpad: if there is no frame to clone return early 2022-02-24 21:28:23 +01:00
James Almer
a2b090da79 avcodec/libsvtav1: fix compilation with old SVT-AV1 builds
Signed-off-by: James Almer <jamrial@gmail.com>
2022-02-24 16:34:16 -03:00
James Almer
c33b404885 avcodec/libsvtav1: add a svtav1-params option to pass a list of key=value parameters
Signed-off-by: James Almer <jamrial@gmail.com>
2022-02-24 14:57:00 -03:00
Andreas Rheinhardt
636631d9db Remove unnecessary libavutil/(avutil|common|internal).h inclusions
Some of these were made possible by moving several common macros to
libavutil/macros.h.

While just at it, also improve the other headers a bit.

Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
84f16bb5e6 avutil/avassert: Don't include avutil.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
155cd6baa4 Remove obsolete version.h inclusions
Forgotten in e7bd47e657.

Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
b389ff9a85 avutil/display: Don't include avutil.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
2c2d76b50d avutil/integer: Don't include common.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
94d5892bea avutil/pixelutils: Don't include common.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
8e7d2e4621 avutil/samplefmt: Don't include attributes.h, avutil.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
e82d94ee46 avutil/imgutils: Don't include avutil.h
It is a remnant of an FF_API_* inclusion (back from when they were in
avutil.h and not in version.h).

Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
9d78acd861 avutil/eval: Don't include avutil.h
It has been added for an FF_API_* at a time when these were in avutil.h.

Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
eaba16ba70 avutil/file: Don't include avutil.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
0a1a8fcd56 avutil/fifo: Don't include avutil.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
99b5956af1 avutil/audio_fifo: Avoid avutil.h inclusion
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
321a3c244d avutil/log: Don't include avutil.h
It has been included since af5f434f8c
for deprecation reasons, but removing it has been forgotten after
it had served is purpose. So remove it.

For convenience, include version.h instead as LIBAVUTIL_VERSION_INT
is supposed to be used when creating AVClasses.

Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Andreas Rheinhardt
12a540352b avformat/avio: Don't include common.h
Reviewed-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-24 12:56:49 +01:00
Gyan Doshi
8ef03c2ff1 doc/muxers: note video_track_timecale in mov 2022-02-24 16:11:26 +05:30
Paul B Mahol
15a1104d73 avfilter/f_ebur128: multiply is usually faster than divide
Also guard against overflow when subtracting from unsigned.
2022-02-24 11:15:28 +01:00
Paul B Mahol
d5ad1d7847 avfilter/f_ebur128: use unsigned for hist_entry.count
Also when summing multiple hist_entry.count use uint64_t for accumulator.
2022-02-24 11:15:28 +01:00
Paul B Mahol
b0f8dbb0ca avfilter/af_loudnorm: increase max allowed LRA 2022-02-23 23:25:58 +01:00
Stephen Hutchinson
ce0000dc98 avformat/avisynth: remove framedata variable
It's just a simple index.

Addresses Coverity issue 1500290

Signed-off-by: Stephen Hutchinson <qyot27@gmail.com>
2022-02-23 12:59:15 -05:00
Stephen Hutchinson
5df71a5e8d avformat/avisynth: remove unused variable 'frameprop'
Since the check got simplified and stdbool was no longer necessary
to include, neither is that variable.  Silences a warning.

Signed-off-by: Stephen Hutchinson <qyot27@gmail.com>
2022-02-23 12:59:11 -05:00
Paul B Mahol
d27e1cb633 avfilter/avf_showfreqs: stop using audio fifo
Also stop rewriting pts.
2022-02-23 17:01:36 +01:00
Jiasheng Jiang
9cf652cef4 avformat/nutdec: Add check for avformat_new_stream
Check for failure of avformat_new_stream() and propagate
the error code.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2022-02-23 14:13:16 +01:00
Andreas Rheinhardt
b14321e307 avcodec/magicyuvenc: Remove unused context variable
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-23 11:52:28 +01:00
Andreas Rheinhardt
095ccc7b33 avcodec/magicyuvenc: Don't modify input frame
It need not be writable at all. Instead, use temporary buffers
for decorrelation.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-23 11:52:20 +01:00
Andreas Rheinhardt
416d4be626 avcodec/magicyuvenc: Add const where appropriate
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-23 11:52:03 +01:00
Andreas Rheinhardt
f57e522ce2 avcodec/magicyuvenc: Avoid unnecessary av_frame_clone()
It is unnecessary and unchecked; the intention seems to be to ensure
that the frame's data is writable, but it does not provide this.
This will be fixed in a latter commit.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-23 11:51:41 +01:00
Andreas Rheinhardt
047a4e580e fftools/ffprobe: Remove redundant checks
A decoder is only opened if there is a decoder for the codec,
so every AVCodecContext here has AVCodecContext.codec set.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-23 11:50:48 +01:00
Andreas Rheinhardt
26cce232d7 fftools/ffprobe: Flush decoder after draining
This is a prerequisite to continue using the decoder at all
to decode the next interval (if any).
This fixes a regression introduced in commit
2a88ebd096 and reported in ticket #8657.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-23 11:50:48 +01:00
Paul B Mahol
570fda56b9 avfilter/af_surround: use outlink variable already available 2022-02-22 22:50:38 +01:00
Paul B Mahol
f984383ea0 avfilter/af_afftfilt: stop resetting pts
Also stop using audio fifo.
2022-02-22 22:50:38 +01:00
Paul B Mahol
fee804f7ed avfilter/af_surround: do not rewrite pts any more
Also stop using fifo and excessive peeking.
2022-02-22 13:25:21 +01:00
Paul B Mahol
c337b0f826 avfilter/af_afir: remove pts rewriting code
This is not needed at all.
2022-02-22 13:25:21 +01:00
Thilo Borgmann
a473e11e32 lavd/avfoundation: Fix mixed declaration and code 2022-02-22 13:10:42 +01:00
Zhao Zhili
079de49912 avdevice/avfoundation: check strdup 2022-02-22 13:06:59 +01:00
Zhao Zhili
6b708592fa avdevice/avfoundation: fix memleak 2022-02-22 13:02:02 +01:00