Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-09-03avcodec/codec_internal: Add macro to set AVCodec.long_nameAndreas Rheinhardt
It reduces typing: Before this patch, there were 105 codecs whose long_name-definition exceeded the 80 char line length limit. Now there are only nine of them. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-04-05avcodec/codec_internal: Use union for FFCodec decode/encode callbacksAndreas Rheinhardt
This is possible, because every given FFCodec has to implement exactly one of these. Doing so decreases sizeof(FFCodec) and therefore decreases the size of the binary. Notice that in case of position-independent code the decrease is in .data.rel.ro, so that this translates to decreased memory consumption. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-04-05avcodec/codec_internal: Make FFCodec.decode use AVFrame*Andreas Rheinhardt
This increases type-safety by avoiding conversions from/through void*. It also avoids the boilerplate "AVFrame *frame = data;" line for non-subtitle decoders. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-03-21avcodec/codec_internal: Add FFCodec, hide internal part of AVCodecAndreas Rheinhardt
Up until now, codec.h contains both public and private parts of AVCodec. This exposes the internals of AVCodec to users and leads them into the temptation of actually using them and forces us to forward-declare structures and types that users can't use at all. This commit changes this by adding a new structure FFCodec to codec_internal.h that extends AVCodec, i.e. contains the public AVCodec as first member; the private fields of AVCodec are moved to this structure, leaving codec.h clean. Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-09avcodec/thread: Don't use ThreadFrame when unnecessaryAndreas Rheinhardt
The majority of frame-threaded decoders (mainly the intra-only) need exactly one part of ThreadFrame: The AVFrame. They don't need the owners nor the progress, yet they had to use it because ff_thread_(get|release)_buffer() requires it. This commit changes this and makes these functions work with ordinary AVFrames; the decoders that need the extra fields for progress use ff_thread_(get|release)_ext_buffer() which work exactly as ff_thread_(get|release)_buffer() used to do. This also avoids some unnecessary allocations of progress AVBuffers, namely for H.264 and HEVC film grain frames: These frames are not used for synchronization and therefore don't need a ThreadFrame. Also move the ThreadFrame structure as well as ff_thread_ref_frame() to threadframe.h, the header for frame-threaded decoders with inter-frame dependencies. Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2022-02-08all: Remove unnecessary libavcodec/internal.h inclusionsAndreas Rheinhardt
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-04-27avcodec: Constify AVCodecsAndreas Rheinhardt
Given that the AVCodec.next pointer has now been removed, most of the AVCodecs are not modified at all any more and can therefore be made const (as this patch does); the only exceptions are the very few codecs for external libraries that have a init_static_data callback. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
2021-02-28avcodec/dxtory: Fix undefined shift with negative linesizeMichael Niedermayer
Fixes: left shift of negative value -128 Fixes: 30746/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-5906271469436928 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>
2020-10-04avcodec/dxtory: Fix negative stride shift in dx2_decode_slice_420()Michael Niedermayer
Fixes: left shift of negative value -640 Fixes: 26044/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-5631057602543616 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>
2020-09-26avcodec/dxtory: Fix negative shift in dx2_decode_slice_410()Michael Niedermayer
Fixes: left shift of negative value -768 Fixes: 25574/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-6012596027916288 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>
2020-09-26avcodec/dxtory: Fix negative shift in dxtory_decode_v1_410()Michael Niedermayer
Fixes: left shift of negative value -256 Fixes: 25460/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-5073252341514240 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>
2020-09-26avcodec/dxtory: Fix get_raw_size() for YUVMichael Niedermayer
Fixes: out of array read Fixes: 25455/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-6327985731534848 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>
2020-09-05avcodec/dxtory: add frame threads supportPaul B Mahol
2020-09-05avcodec/dxtory: add missed rgb555/rgb565 formats for vflip casePaul B Mahol
2020-09-05avcodec/dxtory: support subsampled formats with non-aligned sizePaul B Mahol
Also unbreak decoding after 6e1a167c556
2020-09-03avcodec/dxtory: add support for vertically flipped framesPaul B Mahol
2019-04-24avcodec/dxtory: Check slice_size against minimum in dxtory_decode_v2()Michael Niedermayer
Fixes: Timeout (33sec -> 16 milli sec) Fixes: 14181/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-5681840708386816 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-03-25avcodec/dxtory: Check slice sizes before allocating imageMichael Niedermayer
Fixes: Timeout (26sec -> 2sec) Fixes: 13612/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_DXTORY_fuzzer-5676845977042944 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-02-20avcodec/dxtory: Remove code that corrupts dimensionsMichael Niedermayer
Fixes: Timeout Fixes: 5796/clusterfuzz-testcase-minimized-5206729085157376 Does someone have a valid sample that triggers this path ? Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2018-01-23avcodec/dxtory: Fix bits left checksMichael Niedermayer
Fixes: Timeout Fixes: 4863/clusterfuzz-testcase-6347354178322432 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-03-27Merge commit '7a2b2b6a92c4b528ecb640790eca0aa790d858f4'Clément Bœsch
* commit '7a2b2b6a92c4b528ecb640790eca0aa790d858f4': dxtory: Drop nonsense ISO C printf conversion specifiers for standard types Merged-by: Clément Bœsch <u@pkh.me>
2016-10-28dxtory: Drop nonsense ISO C printf conversion specifiers for standard typesDiego Biurrun
2016-06-29Merge commit 'b668662939de3a02454cfc9ba3e6d10b87527a40'Clément Bœsch
* commit 'b668662939de3a02454cfc9ba3e6d10b87527a40': get_bits: Move BITSTREAM_READER_LE definition before all relevant #includes The merge commit also includes changes for libavcodec/interplayacm.c and libavcodec/truemotion2rt.c Merged-by: Clément Bœsch <clement@stupeflix.com>
2016-06-07get_bits: Move BITSTREAM_READER_LE definition before all relevant #includesDiego Biurrun
This avoids the danger that get_bits.h might get indirectly #included before BITSTREAM_READER_LE is defined. Also sort headers into canonical order where appropriate.
2016-03-30Mark tables used only within their files as staticDiego Biurrun
2015-11-15avcodec/dxtory: Fix input size check in dxtory_decode_v1_410()Michael Niedermayer
Fixes potential out of array read Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-11-15avcodec/dxtory: Fix input size check in dxtory_decode_v1_420()Michael Niedermayer
Fixes out of array read Fixes: c50c4aa6cefda71b19a31ea12302980c/asan_heap-oob_12be5fd_7011_33ebd015a74976215934add72b9c8352.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-08Merge commit 'd0f7e4a57fbffa0efb204d4274c3dd56fbfff946'Hendrik Leppkes
* commit 'd0f7e4a57fbffa0efb204d4274c3dd56fbfff946': dxtory: Unify and rework the decoding routines Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-08Merge commit 'a7e6fbd90e62d3320b1e26d8209fc0f55ee5b0be'Hendrik Leppkes
* commit 'a7e6fbd90e62d3320b1e26d8209fc0f55ee5b0be': dxtory: Factorize the buffer loading Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-08Merge commit '6a6bc43f5f79587b8936334cc0b3a6616f4807ac'Hendrik Leppkes
* commit '6a6bc43f5f79587b8936334cc0b3a6616f4807ac': dxtory: Factorize slice size checks Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-06dxtory: Unify and rework the decoding routinesLuca Barbato
Do not make many assumption on the dimension of the slices and just try to decode additional lines if there is enough data left. Decodes all the samples kindly provided by ultramage.
2015-09-04dxtory: Factorize the buffer loadingLuca Barbato
And the checks nearby it.
2015-09-04dxtory: Factorize slice size checksLuca Barbato
They are always the same.
2015-07-27Merge commit 'def97856de6021965db86c25a732d78689bd6bb0'Michael Niedermayer
* commit 'def97856de6021965db86c25a732d78689bd6bb0': lavc: AV-prefix all codec capabilities Conflicts: cmdutils.c ffmpeg.c ffplay.c libavcodec/8svx.c libavcodec/aacenc.c libavcodec/ac3dec.c libavcodec/adpcm.c libavcodec/alac.c libavcodec/atrac3plusdec.c libavcodec/bink.c libavcodec/dnxhddec.c libavcodec/dvdec.c libavcodec/dvenc.c libavcodec/ffv1dec.c libavcodec/ffv1enc.c libavcodec/fic.c libavcodec/flacdec.c libavcodec/flacenc.c libavcodec/flvdec.c libavcodec/fraps.c libavcodec/frwu.c libavcodec/gifdec.c libavcodec/h261dec.c libavcodec/hevc.c libavcodec/iff.c libavcodec/imc.c libavcodec/libopenjpegdec.c libavcodec/libvo-aacenc.c libavcodec/libvorbisenc.c libavcodec/libvpxdec.c libavcodec/libvpxenc.c libavcodec/libx264.c libavcodec/mjpegbdec.c libavcodec/mjpegdec.c libavcodec/mpegaudiodec_float.c libavcodec/msmpeg4dec.c libavcodec/mxpegdec.c libavcodec/nvenc_h264.c libavcodec/nvenc_hevc.c libavcodec/pngdec.c libavcodec/qpeg.c libavcodec/ra288.c libavcodec/rv10.c libavcodec/s302m.c libavcodec/sp5xdec.c libavcodec/takdec.c libavcodec/tiff.c libavcodec/tta.c libavcodec/utils.c libavcodec/v210dec.c libavcodec/vp6.c libavcodec/vp9.c libavcodec/wavpack.c libavcodec/yop.c Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27lavc: AV-prefix all codec capabilitiesVittorio Giovara
Express bitfields more simply. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-02-14avcodec/dxtory: use init_get_bits8()Paul B Mahol
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-02-01avcodec/dxtory: Use LL instead of L number suffixMichael Niedermayer
This is probably unneeded and normal int would be fine, but its safer to use LL and this isnt speed relevant Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-10-30avcodec/dxtory: use unaligned copy for unaligned addressesMichael Niedermayer
Fixes undefined behavior Fixes: asan_heap-oob_112c6b3_13_012.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-09-26avcodec/dxtory: remove unused variablesMichael Niedermayer
Found-by: Benoit Fouet <benoit.fouet@free.fr> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-09-26avcodec/dxtory: Support dxtory-2.0.127.aviMichael Niedermayer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-22Merge commit 'cc8163e1a3601a56f722a4720516e860bf1c6198'Michael Niedermayer
* commit 'cc8163e1a3601a56f722a4720516e860bf1c6198': avcodec: more correct printf specifiers Conflicts: libavcodec/4xm.c libavcodec/alsdec.c libavcodec/dfa.c libavcodec/h264_ps.c libavcodec/jpeg2000dec.c libavcodec/lagarith.c libavcodec/mpeg12dec.c libavcodec/rv10.c libavcodec/svq3.c libavcodec/wmaprodec.c libavcodec/xwddec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-22avcodec: more correct printf specifiersDiego Biurrun
2014-02-17avcodec/dxtory: fix src size checksMichael Niedermayer
Fixes integer overflow Fixes out of array read Fixes: d104661bb59b202df7671fb19a00ca6c-asan_heap-oob_d6429d_5066_cov_1729501105_dxtory_mic.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-25Merge remote-tracking branch 'qatar/master'Michael Niedermayer
* qatar/master: dxtory: compressed RGB555/RGB565 decoding support Conflicts: libavcodec/dxtory.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-25Merge commit '0e1ad2f591b87e944550c15b54e54f8189743289'Michael Niedermayer
* commit '0e1ad2f591b87e944550c15b54e54f8189743289': dxtory: add more compressed and uncompressed modes Conflicts: libavcodec/dxtory.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-24dxtory: compressed RGB555/RGB565 decoding supportKostya Shishkov
2014-01-24dxtory: add more compressed and uncompressed modesKostya Shishkov
2014-01-22Merge commit '025fd76e1a2623c858d8c686a73cc30980a314b0'Michael Niedermayer
* commit '025fd76e1a2623c858d8c686a73cc30980a314b0': dxtory: change error code for unexpected slice configuration Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-22Merge commit 'e91a3f1bdba9b4945e42c191d2e35e9844625fb4'Michael Niedermayer
* commit 'e91a3f1bdba9b4945e42c191d2e35e9844625fb4': dxtory: correctly handle YUV slices with average odd height Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-21dxtory: change error code for unexpected slice configurationKostya Shishkov