summaryrefslogtreecommitdiff
path: root/libavcodec
Commit message (Collapse)AuthorAge
* avformat/isom: Split movaudio/movvideo tags off into a separate fileAndreas Rheinhardt2021-02-23
| | | | | | | | | The NUT and avi demuxers only need ff_codec_movvideo_tags and so this removes a dependency on the rest of isom.c as well as on mpeg4audio.c (which isom depends on); it is similar for the Matroska demuxer and muxers, except that the mpeg4audio.c dependency can't be avoided. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/Makefile: Remove outdated dependency of FLV demuxer on mpeg4audioAndreas Rheinhardt2021-02-23
| | | | | | | Unneeded since f96a653184e63cea91e08ea75ae60d309e431f40 and b2bb09bcc330156e9d79d7ddfa59f9c5d05ca149. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/mpeg4audio: Use proper logcontext for loggingAndreas Rheinhardt2021-02-23
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/scpr3: Avoid code duplication when updating modelsAndreas Rheinhardt2021-02-23
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/Makefile: Don't build mjpegenc_huffman unconditionallyAndreas Rheinhardt2021-02-23
| | | | | | | Only the mjpeg and amv encoders as well as its testprogram actually need it. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/mjpegenc_common: Move stuff only used by mjpegenc.c to itAndreas Rheinhardt2021-02-23
| | | | | | | | This allows to make ff_init_uni_ac_vlc static; ff_mjpeg_encode_picture_frame has also been made static, but it could always have been made static. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/jpegtables: Move ff_mjpeg_build_huffman_codes to mjpegenc_commonAndreas Rheinhardt2021-02-23
| | | | | | | Since g2meet.c doesn't use it any more, only encoders use it and the place for their common code is mjpegenc_common.c. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/g2meet, mjpegdec: Factor out common VLC initialization codeAndreas Rheinhardt2021-02-23
| | | | | | | | | While just at it, remove the nb_codes parameter: It is redundant (the number of codes is implicitly contained in the array containing how many entries of a specific size there are) and for this reason it might even be wrong, so it is better to check what is actually used instead. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/Makefile: Remove redundant mjpegdec dependency from tiff decoderAndreas Rheinhardt2021-02-23
| | | | | | | | The MJPEG decoder is already activated by configure whenever the tiff decoder is selected; ergo it is unnecessary to add a dependency in the Makefile. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* configure, libavcodec/Makefile: Fix avrn dependenciesAndreas Rheinhardt2021-02-23
| | | | | | | | | | | The avrn decoder actually only needs one thing: The MJPEG decoder. Instead the Makefile made it compile mjpegdec and configure required some of the prerequisites of the MJPEG decoder (exif and jpegtables). Even if all the prerequisites of the MJPEG decoder were required, it would still not make the MJPEG decoder usable, because for that the MJPEG decoder needs to be in the list of codecs in codec_list.c. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/avrndec: Remove unnecessary headersAndreas Rheinhardt2021-02-23
| | | | | | | The avrn decoder does not use any internals of the MJPEG decoder since e0031ca29a471c4a540ba2e01b3f81af03ef757b. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/Makefile: Remove spurios dcaenc dependencyAndreas Rheinhardt2021-02-23
| | | | | | It does not need dca.c. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* configure, libavcodec/Makefile: Remove spurious CAF demuxer dependenciesAndreas Rheinhardt2021-02-23
| | | | | | Forgotten in 604fbb3132e88727e496c96c92cfe02748c25a1a. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec: remove pointless lowres deprecation wrappersJames Almer2021-02-22
| | | | | | | | Neither the feature, public fields, or AVOptions were ever truly deprecated, nor will have been removed if this FF_API_ define was left in place, so get rid of it as it's misleading. Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/mjpegdec: Cleanup ff_smvjpeg_decoder()Michael Niedermayer2021-02-22
| | | | | | | | | | Fixes: memleaks Fixes: 28533/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SMVJPEG_fuzzer-6242529653686272 Fixes: 30594/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_SMVJPEG_fuzzer-6549216035995648 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/cri: Stop the bitreader at the end of uncompressed inputMichael Niedermayer2021-02-22
| | | | | | | | | Fixes: Timeout Fixes: 29983/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CRI_fuzzer-6420415838814208 Fixes: 30595/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CRI_fuzzer-6559089360502784 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/cuviddec: set ulMaxDisplayDelay to zero if low_delay flag is setMichal Novotny2021-02-22
| | | | | | | Zero is the recommended value in Nvidia coding samples for low latency use-cases. Signed-off-by: Michal Novotny <michal.novotny@comprimato.com> Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
* avcodec/nvenc: don't disable b-frames by defaultRicardo Monteiro2021-02-22
| | | | Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
* lavc/ac3enc: rename variable to avoid shadowingAnton Khirnov2021-02-22
| | | | Harmless, but confusing.
* avcodec: add Simbiosis IMX video decoderPaul B Mahol2021-02-20
|
* avcodec/cpia: Mark decoder as init-threadsafeAndreas Rheinhardt2021-02-20
| | | | | Reviewed-by: Stephan Hilb <stephan@ecshi.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/dirac_vlc: Make ff_dirac_golomb_lut staticAndreas Rheinhardt2021-02-20
| | | | | | | Only used here. Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/ac3tab: Move ff_ac3_enc_channel_map to its only userAndreas Rheinhardt2021-02-20
| | | | | | | and make it static. Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/hapdec: Change compressed_offset to unsigned 32bitMichael Niedermayer2021-02-20
| | | | | | | | | | | Fixes: out of array access Fixes: 29345/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HAP_fuzzer-5401813482340352 Fixes: 30745/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HAP_fuzzer-5762798221131776 Suggested-by: Anton 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>
* avcodec/libvpxenc: optimize parsing vpx_svc_ref_frame_configWonkap Jang2021-02-19
| | | | | | | | Getting rid of unnecessary use of AVDictionary object in parsing vpx_svc_ref_frame_config. Reviewed-by: Nicolas George <george@nsup.org> Signed-off-by: James Zern <jzern@google.com>
* avcodec/cfhdenc: use pts instead of frame numberPaul B Mahol2021-02-19
| | | | Makes encodes bitexact with different number of threads.
* avcodec/indeo3: add support for more dimensionsPaul B Mahol2021-02-19
| | | | Fixes #6581
* lavc/aarch64: add HEVC sao_band NEONJosh Dekker2021-02-18
| | | | | | Only works for 8x8. Signed-off-by: Josh Dekker <josh@itanimul.li>
* lavc/aarch64: add HEVC idct_dc NEONJosh Dekker2021-02-18
| | | | Signed-off-by: Josh Dekker <josh@itanimul.li>
* lavc/aarch64: port HEVC add_residual NEONReimar Döffinger2021-02-18
| | | | | | Speedup is fairly small, around 1.5%, but these are fairly simple. Signed-off-by: Josh Dekker <josh@itanimul.li>
* lavc/aarch64: port HEVC SIMD idct NEONReimar Döffinger2021-02-18
| | | | | | | | | | | | Makes SIMD-optimized 8x8 and 16x16 idcts for 8 and 10 bit depth available on aarch64. For a UHD HDR (10 bit) sample video these were consuming the most time and this optimization reduced overall decode time from 19.4s to 16.4s, approximately 15% speedup. Test sample was the first 300 frames of "LG 4K HDR Demo - New York.ts", running on Apple M1. Signed-off-by: Josh Dekker <josh@itanimul.li>
* avcodec: add initial exr image encoderPaul B Mahol2021-02-18
|
* lavc/aacdec_template: Fix 7.1 decoding with default strictness.KM2021-02-16
| | | | | Broken in 4d9b9c5e Fixes ticket #9057.
* avcodec/frame_thread_encoder: Use more natural typesAndreas Rheinhardt2021-02-16
| | | | | Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Reduce amount of code guarded by mutexAndreas Rheinhardt2021-02-16
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Avoid FIFOAndreas Rheinhardt2021-02-16
| | | | | | It can be replaced by a simple counter. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Avoid allocations of AVFramesAndreas Rheinhardt2021-02-16
| | | | | | | | | | | | | | | | Up until now, when using frame threaded encoding, an AVFrame would be allocated for every frame to be encoded. These AVFrames would reach the worker threads via a FIFO of tasks, a structure which contained the AVFrame as well as an index into an array which gives the place where the worker thread shall put the returned packet; in addition to that, said structure also contained several unused fields. This commit changes this: The AVFrames are now allocated during init in the array that is up until now only used to return the packets. The contents to be encoded are put into the AVFrame in the same array element that is also used to return the packets. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Avoid creating reference to frameAndreas Rheinhardt2021-02-16
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Avoid allocations of AVPackets, fix deadlockAndreas Rheinhardt2021-02-16
| | | | | | | | | | | | | | | | | | | | | Up until now, when doing frame thread encoding, each worker thread tried to allocate an AVPacket for every AVFrame to be encoded; said packets would then be handed back to the main thread, where the content of said packet is copied into the packet actually destined for output; the temporary AVPacket is then freed. Besides being wasteful this also has another problem: There is a risk of deadlock, namely if no AVPacket can be allocated at all. The user doesn't get an error at all in this case and the worker threads will simply try to allocate a packet again and again. If the user has supplied enough frames, the user's thread will block until a task has been completed, which just doesn't happen if no packet can ever be allocated. This patch instead modifies the code to allocate the packets during init; they are then reused again and again. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Fix segfault on allocation errorAndreas Rheinhardt2021-02-16
| | | | | | | | | | | Fixes a segfault from av_fifo_size(NULL) that happens in ff_frame_thread_encoder_free if the fifo couldn't be allocted; furthermore the mutexes and conditions that are destroyed in ff_frame_thread_encoder_free are not even initialized at this point, so don't call said function. Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/frame_thread_encoder: Improve type safetyAndreas Rheinhardt2021-02-16
| | | | | Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avcodec/vp8: Move end check into MB loop in vp78_decode_mv_mb_modes()Michael Niedermayer2021-02-16
| | | | | | | | | Fixes: Timeout (long -> 5sec) Fixes: 30269/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VP7_fuzzer-5430325004075008 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Reviewed-by: Peter Ross <pross@xvid.org> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/exr: export any unknown header string variable to metadataPaul B Mahol2021-02-16
| | | | And properly skip preview type in header.
* avcodec/exr: refactor GetByteContext usagePaul B Mahol2021-02-16
|
* avcodec/exr: correctly calculate display windowPaul B Mahol2021-02-16
|
* avcodec/exr: add multipart supportPaul B Mahol2021-02-16
|
* avcodec/setts_bsf: add sample rate for expressionsPaul B Mahol2021-02-15
|
* avcodec/exr: unbreak parsing sample aspect ratioPaul B Mahol2021-02-15
|
* avcodec/exr: read fps from metadata tooPaul B Mahol2021-02-15
|
* lavc/pnm: Allow decoding gray float pfm images.Carl Eugen Hoyos2021-02-15
|