summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* lavfi/colorspace: add ff_matrix_mul_3x3_vecrcombs2022-06-19
| | | | Signed-off-by: rcombs <rcombs@rcombs.me>
* avdevice/oss_dec: account for sample size when computing timestampMatt Jacobson2022-06-19
| | | | | | | | | Don't assume each sample is one byte in size. Doing so results in wrong and occasionally non-monotonically-increasing timestamps. Fix nearby cosmetic typo. Signed-off-by: Marton Balint <cus@passwd.hu>
* fftools/fopen_utf8: support long paths on Windows for fftoolssoftworkz2022-06-19
| | | | | Signed-off-by: softworkz <softworkz@hotmail.com> Signed-off-by: Martin Storsjö <martin@martin.st>
* avcodec/x86/lpc, vp8dsp_init: Remove redundant checksAndreas Rheinhardt2022-06-18
| | | | | | EXTERNAL_SSE2_SLOW is now more encompassing than EXTERNAL_SSE2. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avutil/cpu_internal: Fix check for SSE2SLOWAndreas Rheinhardt2022-06-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For SSE2 and SSE3, there are four states that the two flags involved (AV_CPU_FLAG_SSE[23] and AV_CPU_FLAG_SSE[23]SLOW) can convey. When ordered from worst to best they are: 1. both flags unset (SSE[23] unavailable) 2. the slow flag set, the ordinary flag unset (this is designed for cases where SSE2 is available, but so slow that MMX(EXT)/SSE code is usually faster) 3. both flags set (SSE2 is available, but there might be scenarios where MMX(EXT)/SSE code is faster) 4. the ordinary flag set, the slow flag unset (this is the normal case) The ordinary macros for checking cpuflags return true in the latter two cases; the fast macros only return true for the latter case. Yet the macros to check for slow currently only return true in case three. This seems unintended. In fact, the only uses of the slow macros are all of the form if (EXTERNAL_SSE2(cpu_flags) || EXTERNAL_SSE2_SLOW(cpu_flags)) where the check for EXTERNAL_SSE2_SLOW is completely redundant. Even more importantly, it is not what was intended. Before 6369ba3c9cc74becfaad2a8882dff3dd3e7ae3c0, the checks passed in cases 2 to 4. Said commit changed this to something that only passes for the third case. Commits 7fb758cd8ed08e4a37f10e25003953d13c68b8cd and c1913064e38cb338039f29c280a0dacc3fd1e451 restored the old behaviour, yet merging 4efab89332ea39a77145e8b15562b981d9dbde68 (in commit ac774cfa571734c49c26e2d3387adccff8957ff8) broke this again by changing it to what it is now.* This commit changes the macros to make the slow macros check whether a specific instruction is supported, even if slow. This restores the intended meaning to all uses of the SLOW macros and is generally more natural. *: Libav only checks for EXTERNAL_SSE2_SLOW, i.e. for the third case only. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/librist: bump required version to 0.2.7Marton Balint2022-06-18
| | | | | | This is the first version for which fifo size setting actually works. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/vlc: Use structure instead of VLC_TYPE array as VLC elementAndreas Rheinhardt2022-06-17
| | | | | | | | | | | | | | | | | | In C, qualifiers for arrays are broken: const VLC_TYPE (*foo)[2] is a pointer to an array of two const VLC_TYPE elements and unfortunately this is not compatible with a pointer to a const array of two VLC_TYPE, because the latter does not exist as array types are never qualified (the qualifier applies to the base type instead). This is the reason why get_vlc2() doesn't accept a const VLC table despite not modifying the table at all, as there is no automatic conversion from VLC_TYPE (*)[2] to const VLC_TYPE (*)[2]. Fix this by using a structure VLCElem for the VLC table. This also has the advantage of making it clear which element is which. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* libavcodec/qsvenc: add ROI support to qsv encoderWenbin Chen2022-06-17
| | | | | | | | | Use The mfxEncoderCtrl parameter to enable ROI. Get side data "AVRegionOfInterest" and use it to configure "mfxExtEncoderROI" which is the MediaSDK's ROI configuration. Signed-off-by: Wenbin Chen <wenbin.chen@intel.com> Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
* avformat/aiffdec: avoid integer overflow in get_meta()Michael Niedermayer2022-06-17
| | | | | | | | Fixes: signed integer overflow: 2147483647 + 1 cannot be represented in type 'int' Fixes: 45891/clusterfuzz-testcase-minimized-ffmpeg_dem_AIFF_fuzzer-6159183893889024 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/aaxdec: Check for overlaping segmentsMichael Niedermayer2022-06-17
| | | | | | | | Fixes: Timeout Fixes: 45875/clusterfuzz-testcase-minimized-ffmpeg_dem_AAX_fuzzer-6121689903136768 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/demux: Count EAGAIN as 100 bytes in relation to read limit in ↵Michael Niedermayer2022-06-17
| | | | | | | | | | | avformat_find_stream_info() Fixes: Timeout Fixes: 43717/clusterfuzz-testcase-minimized-ffmpeg_IO_DEMUXER_fuzzer-5206008287330304 Fixes: 45738/clusterfuzz-testcase-minimized-ffmpeg_IO_DEMUXER_fuzzer-6142535657979904 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/demux: Make read_frame_internal() return AVERREOR(EAGAIN) on stuck ↵Michael Niedermayer2022-06-17
| | | | | | | | | | empty input parser Fixes: read_frame_internal() which does not return even though both demuxer and parser do return Fixes: 43717/clusterfuzz-testcase-minimized-ffmpeg_IO_DEMUXER_fuzzer-5206008287330304 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avdevice/pulse_audio_dec: deprecate frame_size optionMarton Balint2022-06-16
| | | | | | It does not do anything. Frame sizes can be controlled by using fragment_size. Signed-off-by: Marton Balint <cus@passwd.hu>
* avdevice/pulse_audio_dec: reduce default fragment sizeMarton Balint2022-06-16
| | | | | | | | | | | | | Reduces default fragment size from the pulse audio default of 2 sec to 50 ms. This also has an effect on the size of the returned frames, which will be around 50 ms as well, making timestamps more accurate. This should fix the regression in ticket #9776. Pulseaudio timestamps for monitor sources are still pretty inaccurate for me, but I don't see how else should we query latencies from the library. Signed-off-by: Marton Balint <cus@passwd.hu>
* Revert "avdevice/pulse_audio_dec: only set adjust latency flag if ↵Marton Balint2022-06-16
| | | | | | | | | | fragment_size is not set" This reverts commit 7f059a250bb7bcbf7bba537c1a059a5934413035. Apparently adjusting latency makes a difference even if fragment size is specifed. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/matroskaenc: Convert chapter metadataAndreas Rheinhardt2022-06-16
| | | | | | | | | | | | It is no longer converted since mkv_write_chapters() is called before mkv_write_tags() which happens since commit 4ebfc13c338423cf48f1a1266c890422367f7775. Given the fact that chapters can also be written late, mkv_write_chapters() has to convert the metadata itself. Fixes ticket #9812. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/matroskaenc: Reset cur_master_element when discarding masterAndreas Rheinhardt2022-06-16
| | | | | | | | | | | | | | Before this patch the muxer writes an invalid file (namely one in which the Projection master is a child of the Colour element) if the following conditions are met: a) The stream contains AVMasteringDisplayMetadata without primaries and luminance (i.e. useless AVMasteringDisplayMetadata). b) The stream contains AV_PKT_DATA_SPHERICAL side data. c) All the colour elements of the stream are equal to default (i.e. unknown). Fortunately these conditions are very unlikely to be met. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/mxfdec: Offload allocating string to av_dict_set()Andreas Rheinhardt2022-06-16
| | | | | Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/mxfdec: Use ff_data_to_hex() for data->hex conversionAndreas Rheinhardt2022-06-16
| | | | | | | | | | In this case it also stops pretending that the length of the output string is somehow checked (which is currently being done by using snprintf that is called with the amount of space needed instead of the amount of space actually available). Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/mxfdec: Don't duplicate av_uuid_unparseAndreas Rheinhardt2022-06-16
| | | | | | | | Also don't allocate the string ourselves, let av_dict_set() do it. Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/mxf: Use AVUUID for uidsAndreas Rheinhardt2022-06-16
| | | | | | | This is in preparation for using av_uuid functions directly. Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* doc: describe QOI image formatPeter Ross2022-06-16
|
* avfilter/vf_zscale: dissallow too small slicesPaul B Mahol2022-06-16
| | | | Also change rounding type when calculating slices size.
* avcodec/mace: fix some style issuesPaul B Mahol2022-06-16
|
* avfilter: add virtualbass filterPaul B Mahol2022-06-16
|
* doc/APIchanges: add missing marker for release 5.0Gyan Doshi2022-06-16
|
* avcodec/exif: Move tag_list out of headerAndreas Rheinhardt2022-06-15
| | | | | | | | | It is only used by exif.c (and e.g. EXIF_TAG_NAME_LENGTH is an implementation detail anyway). Also remove the sentinel, as it is used in conjunction with FF_ARRAY_ELEMS. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swresample/noise_shaping_data: Remove unused tablesAndreas Rheinhardt2022-06-15
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* all: Replace if (ARCH_FOO) checks by #if ARCH_FOOAndreas Rheinhardt2022-06-15
| | | | | | | | | | | | | | | | | | This is more spec-compliant because it does not rely on dead-code elimination by the compiler. Especially MSVC has problems with this, as can be seen in https://ffmpeg.org/pipermail/ffmpeg-devel/2022-May/296373.html or https://ffmpeg.org/pipermail/ffmpeg-devel/2022-May/297022.html This commit does not eliminate every instance where we rely on dead code elimination: It only tackles branching to the initialization of arch-specific dsp code, not e.g. all uses of CONFIG_ and HAVE_ checks. But maybe it is already enough to compile FFmpeg with MSVC with whole-programm-optimizations enabled (if one does not disable too many components). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat/ape: more bits in size for less overflowsMichael Niedermayer2022-06-14
| | | | | | | | Fixes: signed integer overflow: 2147483647 + 3 cannot be represented in type 'int' Fixes: 46184/clusterfuzz-testcase-minimized-ffmpeg_IO_DEMUXER_fuzzer-4678059519770624 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/binkaudio: Clear state on EAGAINMichael Niedermayer2022-06-14
| | | | | | | | | | | Its not supported to maintain a frame as receive_frame() argument over multiple calls Fixes: store to null pointer of type 'FFTSample' (aka 'float') Fixes: 46231/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_BINKAUDIO_DCT_fuzzer-6276566037954560 Fixes: ACDC.smo Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/mov: Non overflowing ambisonic order checkMichael Niedermayer2022-06-14
| | | | | | | | Fixes: signed integer overflow: 536870913 * 536870913 cannot be represented in type 'int' Fixes: 45862/clusterfuzz-testcase-minimized-ffmpeg_dem_MOV_fuzzer-4730373768085504 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* doc/APIchanges: add missing uuid and csp entriesZane van Iperen2022-06-13
| | | | | Signed-off-by: Zane van Iperen <zane@zanevaniperen.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avutil: bump version after UUID changesZane van Iperen2022-06-13
| | | | | | | Forgot to bump after 76e95daa08f4c8874dbb570b6293716e2175213a. Signed-off-by: Zane van Iperen <zane@zanevaniperen.com> Signed-off-by: James Almer <jamrial@gmail.com>
* swresample/resample: Remove unnecessary emms_cAndreas Rheinhardt2022-06-14
| | | | | | The last MMX code in swresample has just been removed. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swresample/x86/resample: Remove obsolete MMXEXT functionsAndreas Rheinhardt2022-06-14
| | | | | | | | | | | x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). So given that the only systems which benefit from the MMXEXT resamplers (which are overridden by SSE2) are truely ancient 32bit x86s they are removed. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swresample/x86/rematrix: Remove obsolete MMX functionsAndreas Rheinhardt2022-06-14
| | | | | | | | | | | x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2) for x64. So given that the only systems that benefit from these functions are truely ancient 32bit x86s they are removed. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swresample/x86/audio_convert: Remove obsolete MMX functionsAndreas Rheinhardt2022-06-14
| | | | | | | | | | | x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2) for x64. So given that the only systems that benefit from these functions are truely ancient 32bit x86s they are removed. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* swresample/resample: Properly empty MMX stateAndreas Rheinhardt2022-06-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | There is a x86-32 MMXEXT implementation for resampling planar 16bit data. multiple_resample() therefore calls emms_c() if it thinks that this needed. And this is bad: 1. It is a maintenance nightmare because changes to the x86 resample DSP code would necessitate changes to the check whether to call emms_c(). 2. The return value of av_get_cpu_flags() does not tell whether the MMX DSP functions are in use, as they could have been overridden by av_force_cpu_flags(). 3. The MMX DSP functions will never be overridden in case of an x86-32 build with --disable-sse2. In this scenario lots of resampling tests (like swr-resample_exact_lin_async-s16p-8000-48000) fail because the cpuflags indicate that SSE2 is available (presuming that the test is run on a CPU with SSE2). 4. The check includes a call to av_get_cpu_flags(). This is not optimized away for arches other than x86-32. 5. The check takes about as much time as emms_c() itself, making it pointless. This commit therefore removes the check and calls emms_c() unconditionally (it is a no-op for non-x86). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* ffprobe: add -o optionStefano Sabatini2022-06-13
| | | | | | | | | | This enables printing to a resource specified with -o OUTPUT. In case the output is not specified, prints to stdout as usual. Address issue: http://trac.ffmpeg.org/ticket/8024 Signed-off-by: Marton Balint <cus@passwd.hu>
* lavf/avio: add avio_vprintf()Stefano Sabatini2022-06-13
| | | | | | | This new function makes it possible to use avio_printf() functionality from a function taking a variable list of arguments. Signed-off-by: Marton Balint <cus@passwd.hu>
* avfilter/showinfo: refactor to use avutil/uuidPierre-Anthony Lemieux2022-06-12
|
* avformat/imf: refactor to use avutil/uuidPierre-Anthony Lemieux2022-06-12
|
* avformat/smoothstreamingenc: refactor to use avutil/uuidPierre-Anthony Lemieux2022-06-12
|
* avformat/mov: refactor to use avutil/uuidPierre-Anthony Lemieux2022-06-12
|
* avutil/tests/uuid: add uuid testsPierre-Anthony Lemieux2022-06-12
|
* avutil/uuid: add utility library for manipulating UUIDs as specified in RFC 4122Zane van Iperen2022-06-12
| | | | | Co-authored-by: Pierre-Anthony Lemieux <pal@palemieux.com> Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
* doc/ffmpeg: fix typo in VCD creation exampleMarton Balint2022-06-12
| | | | | | Fixes ticket #9753. Signed-off-by: Marton Balint <cus@passwd.hu>
* avcodec/x86/h264_qpel_8bit: Remove unused functionAndreas Rheinhardt2022-06-11
| | | | | | | | | Namely ff_avg_h264_qpel8or16_hv1_lowpass_op_mmxext. It seems to exist since 610e00b3594bf0f2a75713f20e9c4edf0d03a818 (a function like this already existed before that commit, but it was static and av_always_inline and was therefore not present in the actual binaries). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avcodec/x86/rv34dsp: Remove unused ff_rv34_idct_dc_mmxextAndreas Rheinhardt2022-06-11
| | | | | | Forgotten in 9ba9c3402499d90e54f8aa111b62c278206d11af. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>