summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* avformat/movenc: write the major brand also as the first compatible brandJames Almer2019-12-21
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* fftools/ffmpeg: Reindent after last commitNicolas Gaullier2019-12-21
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/icecast: Use AV_DICT_DONT_STRDUP_VAL to save an av_strdupAndreas Rheinhardt2019-12-21
| | | | | | | | | | | This will probably also fix CID 1452559, a false positive where Coverity claims a double-free occurs, because it thinks that av_dict_set() frees its key and value arguments even when the AV_DICT_DONT_STRDUP_* flags aren't used. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Reviewed-by: Marvin Scholz <epirat07@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* fftools/ffmpeg: Fix forward CPB props in to outNicolas Gaullier2019-12-21
| | | | | | | CPB side_data is copied when stream-copying (see init_output_stream_streamcopy()), but it shall not be copied when the stream is decoded. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avfilter/vf_readeia608: if parity bit check fails, set correct valuePaul B Mahol2019-12-21
| | | | As described in U.S. Federal Register, Volume 56, Number 114, June 13, 1991, pages 27204-27205.
* avcodec/h264_sei: fix the size of user data unregisteredLimin Wang2019-12-20
| | | | | | | According to the specifications, the payloadSize includes the 16-byte size of UUID. Signed-off-by: Limin Wang <lance.lmwang@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* doc/encoders: correct the description for ts_target_bitrateWonkap Jang2019-12-20
| | | | | | | ts_target_bitrate is in kbps, not bps. This commit clarifies the unit and modifies the example to match the description. Signed-off-by: James Zern <jzern@google.com>
* avfilter/vf_readeia608: rewrite processing, make extracting more robustPaul B Mahol2019-12-20
| | | | Lots of options are now obsolete.
* avcodec/hevc_sei: switch to AVBufferRef buffer for a53 captionLimin Wang2019-12-20
| | | | | Signed-off-by: Limin Wang <lance.lmwang@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/icecast: Free the right buffer on errorAndreas Rheinhardt2019-12-19
| | | | | | | | | | | | | | | In case an AVBPrint was not complete, icecast_open() would free some buffers that have not been allocated yet instead of freeing the data of the AVBPrint (if they have been allocated). Because this error does not trigger a jump to the general cleanup section any more, one can moreover remove a (now unnecessary) initialization of a pointer. Furthermore, finalizing an AVBPrint can fail (namely when the string inside the AVBPrint has not been allocated yet) and so this needs to be checked. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/tls_openssl: don't use libcrypto locking functions with newer ↵James Almer2019-12-19
| | | | | | | | | | | OpenSSL versions They have been removed altogether without a compat implementation, and are either no-ops or return NULL. This fixes compiler warnings about checks always evaluating to false, and leaks of allocated mutexes. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/cbs_av1: add missing valid range of values for num_cb_points and ↵James Almer2019-12-19
| | | | | | | | | num_cr_points It is a requirement of bitstream conformance that num_cr_points is less than or equal to 10. It is a requirement of bitstream conformance that num_cb_points is less than or equal to 10. Signed-off-by: James Almer <jamrial@gmail.com>
* checkasm: aacpsdsp: Tolerate extra intermediate precision in stereo_interpolateMartin Storsjö2019-12-18
| | | | | | | | | | | | | | | | | | | | | | The stereo_interpolate functions add h_step to the values h BUF_SIZE times. Within the stereo_interpolate C functions, the values h (h0-h3, h00-h13) are declared as local float variables, but the compiler is free to keep them in a register with extra precision. If the accumulation is rounded to 32 bit float precision after each step, the less significant bits of h_step end up ignored and the sum can deviate, affecting the end result more than the currently set EPS. By clearing the log2(BUF_SIZE) lower bits of h_step, we make sure that the accumulation shouldn't differ significantly, regardless of any extra precision in the accmulating register/variable. This fixes the aacpsdsp checkasm test when built with clang for mingw/x86_32. Signed-off-by: Martin Storsjö <martin@martin.st>
* ffprobe: Fix fate tests for ffprobe in cases where TARGET_PATH differs from ↵Martin Storsjö2019-12-18
| | | | | | | | | | | | | | | | | | | the current path In these cases, we must pass the full path of the file to ffprobe (as the current working dir on the remote system, e.g. when invoked with "ssh remote ffprobe ..." isn't the wanted one). The input filename passed to ffprobe is also included in the output, which is part of the reference test data. Add a new option to ffprobe to allow overriding what path is printed, to keep the original relative path in the tests. An alternative approach could be an option to allow requesting omitting the file name from the dumped data, and updating the test references accordingly. Signed-off-by: Martin Storsjö <martin@martin.st>
* swscale/aarch64: use multiply accumulate and increase vector factor to 4Sebastian Pop2019-12-17
| | | | | | | | | | | | | | | | | | | | | This patch implements ff_hscale_8_to_15_neon with NEON fused multiply accumulate and bumps the vectorization factor from 2 to 4. The speedup is of 25% on Graviton1 A1 instances based on A-72 cpus: $ ffmpeg -nostats -f lavfi -i testsrc2=4k:d=2 -vf bench=start,scale=1024x1024,bench=stop -f null - before: t:0.040303 avg:0.040287 max:0.040371 min:0.039214 after: t:0.032168 avg:0.032215 max:0.033081 min:0.032146 The speedup is of 39% on Graviton2 m6g instances based on Neoverse-N1 cpus: $ ffmpeg -nostats -f lavfi -i testsrc2=4k:d=2 -vf bench=start,scale=1024x1024,bench=stop -f null - before: t:0.019446 avg:0.019423 max:0.019493 min:0.019181 after: t:0.014015 avg:0.014096 max:0.015018 min:0.013971 Tested with `make check` on aarch64-linux. Signed-off-by: Sebastian Pop <spop@amazon.com> Reviewed-by: Jean-Baptiste Kempf <jb@videolan.org> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavc/h264dec.h: remove unused ff_h264_decode_slice_headerLinjie Fu2019-12-17
| | | | | | | | | Once removed in 4a9bab3db0d9ec449ebc8b5e823374d1d1df7761. Introduced again in b25cd7540e7. Signed-off-by: Linjie Fu <fulinjie@zju.edu.cn> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* FATE/hevc.mak: cosmetic for fate-hevc-paired-fieldsLinjie Fu2019-12-17
| | | | | | | Adjust the order of fate-hevc-paired-fields. Signed-off-by: Linjie Fu <linjie.fu@intel.com> Signed-off-by: James Almer <jamrial@gmail.com>
* FATE: add test for hevc files with 4 TUDepth(0..4) of cbf_cb/cbf_crLinjie Fu2019-12-17
| | | | | | | | | | | 5 cabac states for cbf_cb and cbf_cr are supported according to Table 9-4. Add a test for 64x64 4:4:4 8bit HEVC clips with TUDepth = 4, cbf_cr > 0. Signed-off-by: Xu Guangxin <guangxin.xu@intel.com> Signed-off-by: Linjie Fu <linjie.fu@intel.com> Signed-off-by: James Almer <jamrial@gmail.com>
* lavc/hevc_cabac: fix cbf_cb and cbf_cr for transform depth 4Linjie Fu2019-12-17
| | | | | | | | | | | The max transform depth is 5(from 0 to 4), so we need 5 cabac states for cbf_cb and cbf_cr. See Table 9-4 for details. Signed-off-by: Xu Guangxin <guangxin.xu@intel.com> Signed-off-by: Linjie Fu <linjie.fu@intel.com> Signed-off-by: James Almer <jamrial@gmail.com>
* vc2enc: zero padding of the coefficient bufferLynne2019-12-17
| | | | | | | | | | Wavelet types with large amounts of overreading/writing like 9_7 would write into the padding at high wavelet depths, which would remain and be read by the next frame's transform and quickly cause artifacts to appear for subsequent frames. This fix affects all frames encoded with a non-power-of-two width, with the artifacts varying between non-observable to very noticeable, depending on encoder settings, so reencoding is advisable.
* avfilter/vf_stack: set framerate to VFR when inputs frame rates differsPaul B Mahol2019-12-17
|
* fate: Add an option for disabling the 2k/4k testsMartin Storsjö2019-12-17
| | | | | | | | When testing on a memory limited system, these tests consume a significant amount of memory and can often fail if testing by running multiple processes in parallel. Signed-off-by: Martin Storsjö <martin@martin.st>
* lavc/vaapi_encode: grow packet if vaMapBuffer returns multiple buffersLinjie Fu2019-12-17
| | | | | | | | | | | | Currently, assigning new buffer for pkt when multiple buffers were returned from vaMapBuffer will overwrite the previous encoded pkt data and lead to encode issues. Iterate through the buf_list first to find out the total buffer size needed for the pkt, allocate the whole pkt to avoid repeated reallocation and memcpy, then copy data from each buf to pkt. Signed-off-by: Linjie Fu <linjie.fu@intel.com>
* avfilter: Add tonemap vaapi filter for H2SXinpeng Sun2019-12-17
| | | | | | | | | | | | | It performs HDR(High Dynamic Range) to SDR(Standard Dynamic Range) conversion with tone-mapping. It only supports HDR10 as input temporarily. An example command to use this filter with vaapi codecs: FFMPEG -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -hwaccel_output_format vaapi \ -i INPUT -vf 'tonemap_vaapi=format=p010' -c:v hevc_vaapi -profile 2 OUTPUT Signed-off-by: Xinpeng Sun <xinpeng.sun@intel.com> Signed-off-by: Zachary Zhou <zachary.zhou@intel.com> Signed-off-by: Ruiling Song <ruiling.song@intel.com>
* lavc/allcodecs: Add mpeg4 omx encoder, missed in 0e387232Carl Eugen Hoyos2019-12-16
|
* lavu/log: Also print the log level for level trace.Carl Eugen Hoyos2019-12-16
|
* lavc/cbs_h2645_syntax_template: Fix memleakAndriy Gelman2019-12-16
| | | | | | | | | | | | | | | | | payload_count is used to track the number of SEI payloads. It is also used to free the SEIs in cbs_h264_free_sei()/cbs_h265_free_sei(). Currently, payload_count is set after for loop is completed. Hence if there is an error and the function exits, the payload remains zero causing a memleak. This commit keeps track of payload_count inside the for loop to fix the issue. Note that that the contents of current are initialized with av_mallocz() so there is no need to zero initialize payload_count. Found-by: libFuzzer Reviewed-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: Andriy Gelman <andriy.gelman@gmail.com>
* h264_mp4toannexb: Remove unnecessary checkAndreas Rheinhardt2019-12-15
| | | | | | | | | | | There can be at most 31 SPS and 255 PPS in the mp4/Matroska extradata. Given that each has a size of at most 2^16-1, the length of the output derived from these parameter sets can never overflow an ordinary 32 bit integer. So use a simple uint32_t instead of uint64_t and replace the unnecessary check with an av_assert1. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/adpcm: Clip predictor for APCMichael Niedermayer2019-12-15
| | | | | | | | Fixes: signed integer overflow: -2147483648 - 13 cannot be represented in type 'int' Fixes: 18893/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_ADPCM_IMA_APC_fuzzer-5630760442920960 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/targa: Check colors vs. available spaceMichael Niedermayer2019-12-15
| | | | | | | | Fixes: Timeout (37sec -> 52ms) Fixes: 18892/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TARGA_fuzzer-5739537854889984 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* tools/target_dec_fuzzer: Adjust threshold for dstMichael Niedermayer2019-12-15
| | | | | | | | Fixes: Timeout (400sec -> 14sec) Fixes: 18989/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DST_fuzzer-5175008116867072 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/dstdec: Use get_ur_golomb_jpegls()Michael Niedermayer2019-12-15
| | | | | | | | | Fixes: shift exponent -4 is negative Fixes: 17793/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DST_fuzzer-5766088435957760 Fixes: 18989/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DST_fuzzer-5175008116867072 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/wmavoice: Check remaining input in parse_packet_header()Michael Niedermayer2019-12-15
| | | | | | | | Fixes: Infinite loop Fixes: 18914/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMAVOICE_fuzzer-5731902946541568 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/wmalosslessdec: Fix 2 overflows in mclmsMichael Niedermayer2019-12-15
| | | | | | | | Fixes: signed integer overflow: 2038337026 + 109343477 cannot be represented in type 'int' Fixes: 18886/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMALOSSLESS_fuzzer-5673660505653248 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/decode: Fix integer overflow in max_samples checkMichael Niedermayer2019-12-15
| | | | | | | | Fixes: signed integer overflow: 1677721600 * 32 cannot be represented in type 'int' Fixes: 18885/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FFWAVESYNTH_fuzzer-5741242185154560 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/wmaprodec: Fixes integer overflow with 32bit samplesMichael Niedermayer2019-12-15
| | | | | | | | Fixes: left shift of 1 by 31 places cannot be represented in type 'int' Fixes: 18860/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMAPRO_fuzzer-5755223125786624 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/adpcm: Fix invalid shift in xa_decode()Michael Niedermayer2019-12-15
| | | | | | | | Fixes: left shift of negative value -1 Fixes: 18859/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_ADPCM_XA_fuzzer-5748474213040128 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/wmavoice: Add FF_CODEC_CAP_INIT_CLEANUPMichael Niedermayer2019-12-15
| | | | | | | | Fixes: memleaks Fixes: 18855/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMAVOICE_fuzzer-5687647317524480 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/wmalosslessdec: Fix several integer issuesMichael Niedermayer2019-12-15
| | | | | | | | Fixes: shift exponent -1 is negative (and others) Fixes: 18852/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMALOSSLESS_fuzzer-5660855295541248 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/wmalosslessdec: Check that padding bits is not more than sample bitsMichael Niedermayer2019-12-15
| | | | | | | | Fixes: left shift of 1 by 31 places cannot be represented in type 'int' Fixes: 18817/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WMALOSSLESS_fuzzer-5713317180211200 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/iff: Skip overflowing runs in decode_delta_d()Michael Niedermayer2019-12-15
| | | | | | | | Fixes: Timeout (107sec - 75ms> Fixes: 18812/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_IFF_ILBM_fuzzer-6295585225441280 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/apedec: Set error on error in ape_decode_value_3860()Michael Niedermayer2019-12-15
| | | | | | | | Fixes: Timeout (unknown -> 15sec) Fixes: 18808/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_APE_fuzzer-5677586072207360 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/pnm: Check that the header is not truncatedMichael Niedermayer2019-12-15
| | | | | | | Fixes: Ticket8430 Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/mp3_header_decompress_bsf: Check sample_rate_indexMichael Niedermayer2019-12-15
| | | | | | | | | Fixes: out of array read Fixes: 19309/clusterfuzz-testcase-minimized-ffmpeg_BSF_MP3_HEADER_DECOMPRESS_fuzzer-5651002950942720 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avfilter/x86/vf_interlace: always use unaligned movsMarton Balint2019-12-15
| | | | | | | | | | Fixes crashes in command lines such as: ffmpeg -f lavfi -i testsrc2=704x576:r=50,interlace,pad=720:576:8 -f null none Related to ticket #6491. Signed-off-by: Marton Balint <cus@passwd.hu>
* avfilter/vf_interlace: do not interlace already interlaced framesMarton Balint2019-12-15
| | | | | | The filter used to work this way before it was merged into tinterlace. Signed-off-by: Marton Balint <cus@passwd.hu>
* avfilter/vf_tinterlace: add support for bypassing already interlaced framesMarton Balint2019-12-15
| | | | | | The old interlace filter worked this way before it was merged with tinterlace. Signed-off-by: Marton Balint <cus@passwd.hu>
* avfilter/vf_interlace: restore lowpass mode constantsMarton Balint2019-12-14
| | | | | | | | The documentation still mentions numerical constants in addition to textual ones. It is also wrong to use distinct modes as flags and it disallows us to actually use the flags field for real flags in the future. Signed-off-by: Marton Balint <cus@passwd.hu>
* lavu/pixfmt: Cosmetics, remove wrong end-of-comment markers.Carl Eugen Hoyos2019-12-14
|
* lavc/pnmdec: Fix 16bit decoding.Carl Eugen Hoyos2019-12-14
| | | | | Regression since cdb5479c Reported by irc user tTh from Mixart-Myrys