Commit Graph

114628 Commits

Author SHA1 Message Date
Tong Wu
0faf2ca98a avcodec/d3d12va_decode: remove extra spaces for declaration
Signed-off-by: Tong Wu <tong1.wu@intel.com>
2024-04-03 10:23:05 +08:00
James Almer
50458b7fa1 avformat/isom: don't drop the known layout when parsing AAC decSpecificInfo
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 20:21:13 -03:00
Michael Niedermayer
d157725cf7 avformat/isom: Uninit layout in ff_mp4_read_dec_config_descr()
Fixes: memleak
Fixes: 67442/clusterfuzz-testcase-minimized-ffmpeg_dem_CAF_fuzzer-5068813261406208

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: James Almer <jamrial@gmail.com>
2024-04-02 20:20:04 -03:00
Michael Niedermayer
e3984de6ff
avcodec/exr: Dont use 64bits to hold 6bits
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-03 00:44:38 +02:00
Michael Niedermayer
589fa8a027
avcodec/exr: Check for remaining bits in huf_unpack_enc_table()
Fixes: Timeout
Fixes: 67645/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EXR_fuzzer-6308760977997824

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-03 00:44:38 +02:00
Michael Niedermayer
1887ff250c
avcodec/apedec: Use NABS to avoid undefined negation
Fixes: negation of -2147483648 cannot be represented in type 'int32_t' (aka 'int'); cast to an unsigned type to negate this value to itself
Fixes: 67738/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_APE_fuzzer-5444313212321792

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-03 00:44:38 +02:00
Michael Niedermayer
d58037c18e
avcodec/hevc_ps: --typo
Fixes: null pointer dereference
Fixes: 67737/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HEVC_fuzzer-4858162608930816

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-03 00:44:37 +02:00
Michael Niedermayer
aeb13b03be
tools/target_dec_fuzzer: Adjust threshold for RV30
Fixes: Timeout
Fixes: 67530/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_RV30_fuzzer-6635676118351872

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2024-04-03 00:44:37 +02:00
Mark Samuelson
c52869f36e avcodec/mfenc: expose more properties of the media foundation encoder 2024-04-02 21:45:47 +01:00
Marth64
2204ea00d6 doc/indevs: update CC extraction example to use RCWT muxer
Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:09:05 +02:00
Marth64
0866b2ba5e doc/muxers: refresh the RCWT muxer's doc to be consistent with the demuxer
Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:09:05 +02:00
Marth64
58f04608c2 avformat/rcwtenc: remove repeated documentation
The high level summary of RCWT can be delegated doc/muxers, which
makes it easier to maintain and more consistent with the documentation
of the demuxer.

Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:09:05 +02:00
Marth64
536f0239c0 avformat/rcwtenc: don't assume .bin extension
Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:09:05 +02:00
Marth64
15406f8377 avformat/rcwtdec: add RCWT Closed Captions demuxer
RCWT (Raw Captions With Time) is a format native to ccextractor,
a commonly used OSS tool for processing 608/708 Closed Captions (CC).
RCWT can be used to archive the original extracted CC bitstream.
The muxer was added in January 2024. In this commit, add the demuxer.

One can now demux RCWT files for rendering in ccaption_dec or interop
with ccextractor (which produces RCWT). Using the muxer/demuxer combo,
the CC bits can be kept for processing or rendering with either tool.
This can be an effective way to backup an original CC stream, including
format extensions like EIA-708 and overall original presentation.

Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 20:08:51 +02:00
Stefano Sabatini
dfd9c21754 Changelog: add next entry 2024-04-02 20:04:46 +02:00
Marth64
1c35333671 avformat/subtitles: extend ff_subtitles_queue_insert() to support not yet available events
If ff_subtitles_queue_insert() were given a NULL buffer
with 0 length, it would still attempt to grow the packet
or memcpy depending on if merge option is enabled.

In this commit, allow passing a NULL buffer with 0 length
without attempting to do such operations. This way, if a
subtitle demuxer happens to pass an empty cue or wants to
use av_get_packet() to read bytes, there are no unnecessary
operations on the packet after it is allocated.

Signed-off-by: Marth64 <marth64@proxyid.net>
2024-04-02 19:59:01 +02:00
Nicolas Gaullier
ed9363052f avformat/demux: add duration_probesize AVOption
Yet another probesize used to get the durations when
estimate_timings_from_pts is required. It is aimed at users interested
in better durations probing for itself, or because using
avformat_find_stream_info indirectly and requiring exact values: for
concatdec for example, especially if streamcopying above it.
The current code is a performance trade-off that can fail to get video
stream durations in a scenario with high bitrates and buffering for
files ending cleanly (as opposed to live captures): the physical gap
between the last video packet and the last audio packet is very high in
such a case.

Default behaviour is unchanged: 250k up to 250k << 6 (step by step).
Setting this new option has two effects:
- override the maximum probesize (currently 250k << 6)
- reduce the number of steps to 1 instead of 6, this is to avoid
detecting the audio "too early" and failing to reach a video packet.
Even if a single audio stream duration is found but not the other
audio/video stream durations, there will be a retry, so at the end the
full user-overriden probesize will be used as expected by the user.

Signed-off-by: Nicolas Gaullier <nicolas.gaullier@cji.paris>
2024-04-02 19:53:40 +02:00
Stefano Sabatini
13cdef9d45 doc/muxers: add ircam
Most of the content copy&pasted from:
http://fileformats.archiveteam.org/wiki/Berkeley/IRCAM/Carl_Sound_Format
2024-04-02 19:48:29 +02:00
Stefano Sabatini
026bef7771 doc/muxers/image2: add mention to image2pipe
Clarify the difference with regards to the image2 muxer.
2024-04-02 19:48:28 +02:00
Stefano Sabatini
827889d8f3 doc/muxers/image2: apply misc consistency fixes 2024-04-02 19:48:28 +02:00
Stefano Sabatini
b5488392f0 doc/muxers: add ilbc 2024-04-02 19:48:28 +02:00
Stefano Sabatini
3e4f0b07de doc/muxers: add stub for iamf 2024-04-02 19:48:28 +02:00
Stefano Sabatini
06f17cc9ce doc/muxers/hls: review, apply consistency fixes
Apply misc typo fixes, consistency fixes, and reformat the layout to provide more overall
internal and global consistency.
2024-04-02 19:48:28 +02:00
James Almer
8f85f657d7 RELEASE: update after 7.0 branch
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 13:02:39 -03:00
James Almer
6e52223f3a fate/vvc: add vvc-conformance-IBC_B_Tencent_2
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 12:34:26 -03:00
James Almer
e60d4913ae fate/vvc: add vvc-conformance-SUBPIC_C_ERICSSON_1
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 12:15:03 -03:00
James Almer
e9778d20a4 fate/vvc: disable vvc-conformance-OPI_B_3 and vvc-conformance-VPS_A_3
Both samples rely on a feature our decoder doesn't currently support.

Should fix fate failures on some systems where not even the one single frame
could be generated.

Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 11:50:08 -03:00
James Almer
45b56455ad avcodec/vvc_refs: don't ask for a "Inter layer ref" sample
The FATE suite has two already.

Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 11:48:32 -03:00
Nuo Mi
238bb653e7 avcodec/vvcdec: inter prediction, support subpicture
passed files:
    LMCS_B_Dolby_2.bit
    CodingToolsSets_E_Tencent_1.bit
    SUBPIC_A_HUAWEI_3.bit
    SUBPIC_B_HUAWEI_3.bit
    SUBPIC_C_ERICSSON_1.bit
    SUBPIC_D_ERICSSON_1.bit
    SUBPIC_E_MediaTek_1.bit

passed dvb conformance files (https://dvb.org/specifications/verification-validation/vvc-test-content):
    VVC_HDR_UHDTV1_OpenGOP_3840x2160_50fps_HLG10_mosaic.bit
    VVC_HDR_UHDTV1_OpenGOP_3840x2160_50fps_HLG10_PiP.bit
2024-04-02 20:56:22 +08:00
Nuo Mi
9bc3f3e5fc avcodec/vvcdec: mvs, support subpicture 2024-04-02 20:56:22 +08:00
Nuo Mi
adeb51c30f avcodec/vvcdec: alf, support subpicture 2024-04-02 20:56:22 +08:00
Nuo Mi
bbf0ccb8e7 avcodec/vvcdec: sao, support subpicture 2024-04-02 20:56:22 +08:00
Nuo Mi
0c3018b30a avcodec/vvcdec: sao, refact out tile_edge arrays 2024-04-02 20:56:22 +08:00
Nuo Mi
c9e75393ed avcodec/vvcdec: refact, movie the lc->sc assignment to task_run_stage to simplify the code
This change also make the lc->sc assigned for run_sao
2024-04-02 20:56:22 +08:00
Nuo Mi
8b7304247a avcodec/vvcdec: deblock, support subpicture 2024-04-02 20:56:22 +08:00
Nuo Mi
0d12e9c3c8 avcodec/vvcdec: refact out deblock_is_boundary 2024-04-02 20:56:22 +08:00
Nuo Mi
4020e68d73 avcodec/vvcdec: misc, rename x_ctb, y_ctb, ctu_x, ctu_y to rx, ry to avoid misleading 2024-04-02 20:56:22 +08:00
Nuo Mi
260130aae8 avcodec/vvcdec: ff_vvc_decode_neighbour, support subpicture 2024-04-02 20:56:22 +08:00
Nuo Mi
4e47847119 avcodec/vvcdec: derive subpic position for PPS 2024-04-02 20:56:03 +08:00
Frank Plowman
8078a0b0fa avcodec/vvcdec: support rectangular single-slice subpics
Co-authored-by: Nuo Mi <nuomi2021@gmail.com>
2024-04-02 20:24:31 +08:00
Frank Plowman
9c845e9087 avcodec/vvcdec: fix uninitialized last element of xxx_bd and ctb_to_xxx_bd arrays
see "6.5.1 CTB raster scanning, tile scanning, and subpicture scanning processes"

Co-authored-by: Nuo Mi <nuomi2021@gmail.com>
2024-04-02 20:24:31 +08:00
Nuo Mi
64d5cc67cd avcodec/vvcdec: misc, add specification name for pps members 2024-04-02 20:24:31 +08:00
Nuo Mi
191fbd7ddc avcodec/cbs_h266: fix sh_collocated_from_l0_flag and sh_collocated_ref_idx infer
we have to infer sh_collocated_from_l0_flag and sh_collocated_ref_idx from picture head if pps_rpl_info_in_ph_flag is true
2024-04-02 20:24:31 +08:00
Nuo Mi
cd540a333e avcodec/vvcdec: NoBackwardPredFlag, only check active pictures
see "8.3.6 Decoding process for collocated picture and no backward prediction"
2024-04-02 20:24:31 +08:00
James Almer
8e294abd9d avformat/mov: simplify the entry count overflow check in the keys atom
Suggested-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 09:09:35 -03:00
James Almer
5a06d3810e avformat/mov: don't read key_size bytes twice in the keys atom
We only support mdta as type, yet we were not skipping other types,
but rather reading key_size worth of bytes twice per entry.

Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 00:16:31 -03:00
James Almer
3d12ba77d9 avformat/mov: take into account the first eight bytes in the keys atom
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 00:13:12 -03:00
Eugene Zemtsov
8a23a145d8 avformat/mov: Check if a key is longer than the atom containing it
Stop reading keys and return AVERROR_INVALIDDATA if key_size
is larger than the amount of space left in the atom.

Bug: https://crbug.com/41496983
Signed-off-by: Eugene Zemtsov <eugene@chromium.org>
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-02 00:13:12 -03:00
Andreas Rheinhardt
9d219ff149 avformat/mov: Don't add attached pic if one is already present
Fixes: memleak
Fixes: 67714/clusterfuzz-testcase-minimized-ffmpeg_dem_MOV_fuzzer-5671570999476224

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2024-04-02 04:13:44 +02:00
James Almer
f492f1ac23 avformat/mov: ensure all items id referenced by a grid are valid
Fixes: null pointer dereference
Fixes: 67494/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-6528714521247744

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Tested-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2024-04-01 21:13:04 -03:00