aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/utils.c
Commit message (Collapse)AuthorAgeFilesLines
...
* | avcodec/utils: Check that the data is complete in avpriv_bprint_to_extradata()Michael Niedermayer2014-11-251-0/+5
| | | | | | | | | | | | | | Fixes out of array read Fixes: asan_heap-oob_4d2250_814_cov_2745172097_JACOsub_capability_tester.jss Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Add ATRAC3+ to av_get_audio_frame_duration()Michael Niedermayer2014-11-131-0/+1
| | | | | | | | | | | | Fixes Ticket3979 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Fix warning: comparison between enum foo and enum bar ↵Michael Niedermayer2014-11-101-2/+2
| | | | | | | | | | | | [-Wenum-compare] Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: make sidedata remapping table static constMichael Niedermayer2014-11-101-1/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit 'e3e317e0c015b164b6c2eb8913e393216d78de23'Michael Niedermayer2014-11-101-31/+21
|\| | | | | | | | | | | | | | | | | | | * commit 'e3e317e0c015b164b6c2eb8913e393216d78de23': lavc: Compact the side-data passthrough Conflicts: libavcodec/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavc: Compact the side-data passthroughLuca Barbato2014-11-091-29/+21
| |
* | Merge commit '4ff670d99bebd97429322719089363d83143477d'Michael Niedermayer2014-11-051-5/+5
|\| | | | | | | | | | | | | * commit '4ff670d99bebd97429322719089363d83143477d': hwaccel: Deinitialize hardware acceleration early enough Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hwaccel: Deinitialize hardware acceleration early enoughRémi Denis-Courmont2014-11-041-5/+5
| | | | | | | | | | | | | | | | | | | | | | The application will destroy the underlying hardware handles when get_format() gets called again. Also this ensures the deinitialization takes place if the get_format callback returns an error. Regression from 1c80c9d7ef809180042257200c7b5f6b81d0b0e2. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | lavc/utils: Make pix_fmt desc pointer const.Carl Eugen Hoyos2014-10-301-1/+1
| | | | | | | | Fixes an "initialization discards qualifiers from pointer target type" warning.
* | avcodec/utils: Align dimensions by at least their chroma sub-sampling factors.Michael Niedermayer2014-10-291-2/+6
| | | | | | | | | | | | | | Fixes: out of array accesses Fixes: asan_heap-oob_112c6b3_13_012.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec: Read errno before av_log() as the callback from av_log() might ↵Michael Niedermayer2014-10-251-2/+2
| | | | | | | | | | | | affect errno Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Print the codec name that is missing on the whitelistMichael Niedermayer2014-10-231-1/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec: add codec_whitelistMichael Niedermayer2014-10-191-0/+6
| | | | | | | | | | | | This allows restricting decoders to a list of needed ones for improved security Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Display pixel format information as none ... if unknown ↵Michael Niedermayer2014-10-191-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | instead of omitting it This is similar to 20a5956b8daeee4cb59d6fa00ec809b02c04d7f8 The difference this change makes affects only rather few files but looks like: Stream #0:1: Video: mjpeg, 90k tbr, 90k tbn, 90k tbc vs. Stream #0:1: Video: mjpeg, none(bt470bg/unknown/unknown), 90k tbr, 90k tbn, 90k tbc Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit 'bae557edcea996328e8ff48b9e074a4210f7e6b4'Michael Niedermayer2014-10-171-0/+2
|\| | | | | | | | | | | | | | | | | | | | | * commit 'bae557edcea996328e8ff48b9e074a4210f7e6b4': dump: display codec tags when available Conflicts: libavcodec/utils.c See: d2d7b7134fc387837d51aa1d7f3dbe090d35e8b4 Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * dump: display codec tags when availableVittorio Giovara2014-10-171-0/+13
| | | | | | | | For both audio and video.
* | avcodec/utils: fix time_base after the framerate additionMichael Niedermayer2014-10-151-2/+2
| | | | | | | | | | | | time_base != 1/framerate for example for interlaced video Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit '7ea1b3472a61de4aa4d41b571e99418e4997ad41'Michael Niedermayer2014-10-151-0/+10
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '7ea1b3472a61de4aa4d41b571e99418e4997ad41': lavc: deprecate the use of AVCodecContext.time_base for decoding Conflicts: libavcodec/avcodec.h libavcodec/h264.c libavcodec/mpegvideo_parser.c libavcodec/utils.c libavcodec/version.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavc: deprecate the use of AVCodecContext.time_base for decodingAnton Khirnov2014-10-151-0/+10
| | | | | | | | | | | | | | | | | | | | | | When decoding, this field holds the inverse of the framerate that can be written in the headers for some codecs. Using a field called 'time_base' for this is very misleading, as there are no timestamps associated with it. Furthermore, this field is used for a very different purpose during encoding. Add a new field, called 'framerate', to replace the use of time_base for decoding.
* | Merge commit '2df0c32ea12ddfa72ba88309812bfb13b674130f'Michael Niedermayer2014-10-141-0/+9
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '2df0c32ea12ddfa72ba88309812bfb13b674130f': lavc: use a separate field for exporting audio encoder padding Conflicts: libavcodec/audio_frame_queue.c libavcodec/avcodec.h libavcodec/libvorbisenc.c libavcodec/utils.c libavcodec/version.h libavcodec/wmaenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavc: use a separate field for exporting audio encoder paddingAnton Khirnov2014-10-131-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the amount of padding inserted at the beginning by some audio encoders, is exported through AVCodecContext.delay. However - the term 'delay' is heavily overloaded and can have multiple different meanings even in the case of audio encoding. - this field has entirely different meanings, depending on whether the codec context is used for encoding or decoding (and has yet another different meaning for video), preventing generic handling of the codec context. Therefore, add a new field -- AVCodecContext.initial_padding. It could conceivably be used for decoding as well at a later point.
* | avcodec/utils: Fix "warning: pointer type mismatch in conditional expression"Michael Niedermayer2014-10-091-1/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Add missing AV_PIX_FMT_YUVJ411P to color_range override code.Michael Niedermayer2014-10-091-0/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit '9f3a70c44224ed92d91df65bb9470a2649e7d019'Michael Niedermayer2014-10-091-0/+6
|\| | | | | | | | | | | | | * commit '9f3a70c44224ed92d91df65bb9470a2649e7d019': dump: print the original coded dimensions when available Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * dump: print the original coded dimensions when availableVittorio Giovara2014-10-081-0/+6
| |
* | Merge commit '41e86146e7240f9d42e8cdb86a94bb3eb2bbe15f'Michael Niedermayer2014-10-091-7/+22
|\| | | | | | | | | | | | | | | | | | | * commit '41e86146e7240f9d42e8cdb86a94bb3eb2bbe15f': dump: print detailed color space information full color triplets are only printed if they are not all equal, otherwise they are printed as before Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * dump: print detailed color space informationVittorio Giovara2014-10-081-0/+17
| |
* | avcodec: Allow choosing the dump format field separator.Michael Niedermayer2014-10-091-2/+3
| | | | | | | | | | | | The default is to maintain the previous ", " for now. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit '20a5956b8daeee4cb59d6fa00ec809b02c04d7f8'Michael Niedermayer2014-10-091-4/+12
|\| | | | | | | | | | | | | | | | | | | | | * commit '20a5956b8daeee4cb59d6fa00ec809b02c04d7f8': dump: split audio and video probing on multiple lines Conflicts: libavcodec/utils.c libavformat/dump.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * dump: split audio and video probing on multiple linesVittorio Giovara2014-10-081-7/+12
| | | | | | | | Also always report pixel format.
* | Merge commit '147f2e91eece6b9021ff5b7f8a3b5ce053566659'Michael Niedermayer2014-10-081-0/+5
|\| | | | | | | | | | | | | * commit '147f2e91eece6b9021ff5b7f8a3b5ce053566659': avcodec: make sure color_range is properly initialized Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avcodec: make sure color_range is properly initializedVittorio Giovara2014-10-081-0/+5
| |
* | Merge commit '153fadc390d05aa47e5e2c56290401898fe41a23'Michael Niedermayer2014-10-071-1/+1
|\| | | | | | | | | | | | | * commit '153fadc390d05aa47e5e2c56290401898fe41a23': ff_get_format: fix infinite loop Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * ff_get_format: fix infinite loopRémi Denis-Courmont2014-10-061-1/+1
| | | | | | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* | Merge commit '577899a6458ccad9026eb268f10dc0b39c224c8d'Michael Niedermayer2014-10-061-2/+3
|\| | | | | | | | | | | | | | | | | | | | | | | | | * commit '577899a6458ccad9026eb268f10dc0b39c224c8d': lavc: specify the behavior of av_lockmgr_register on failure. Conflicts: libavcodec/avcodec.h libavcodec/utils.c libavcodec/version.h See: a950edb472e8823e34832c7313ba447b2db76f27 Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavc: specify the behavior of av_lockmgr_register on failure.Manfred Georg2014-10-061-12/+24
| | | | | | | | | | | | | | | | | | | | | | The register function now specifies that the user callback should leave things in the same state that it found them on failure but that failure to destroy is ignored by the library. The register function is now explicit about its behavior on failure (it unregisters the previous callback and destroys all mutex). Signed-off-by: Manfred Georg <mgeorg@google.com> Signed-off-by: Anton Khirnov <anton@khirnov.net>
* | avcodec/utils: Add case for jv to avcodec_align_dimensions2()Michael Niedermayer2014-10-031-0/+4
| | | | | | | | | | | | | | | | Fixes out of array accesses Fixes: asan_heap-oob_12304aa_8_asan_heap-oob_4da4f3_300_intro.jv Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: av_lockmgr_register defines behavior on failure.Manfred Georg2014-10-021-12/+22
| | | | | | | | | | | | | | | | | | | | The register function now specifies that the user callback should leave things in the same state that it found them on failure but that failure to destroy is ignored by the library. The register function is now explicit about its behavior on failure (it unregisters the previous callback and destroys all mutex). Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec, avutil: allow more control about how samples are skippedwm42014-10-021-2/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add CODEC_FLAG2_SKIP_MANUAL (exposed as "skip_manual"), which makes the decoder export sample skip information via side data, instead of applying it automatically. The format of the side data is the same as AV_PKT_DATA_SKIP_SAMPLES, but since AVPacket and AVFrame side data constants overlap, AV_FRAME_DATA_SKIP_SAMPLES needs to be introduced. This is useful for applications which want to do the timestamp calculations manually, or which actually want to retrieve the padding. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Force mutex to NULL after destruction.Manfred Georg2014-10-011-0/+2
| | | | | | | | | | | | A badly behaving user provided mutex manager (such as that in OpenCV) may not reset the mutex to NULL on destruction. This can cause a problem for a later mutex manager (which may assert that the mutex is NULL before creating). Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avcodec/utils: Fix off by 1 error causing unneeded allocation in ↵Michael Niedermayer2014-09-291-1/+1
| | | | | | | | | | | | | | ff_fast_malloc() Reviewed-by: Benoit Fouet <benoit.fouet@free.fr> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit '1c80c9d7ef809180042257200c7b5f6b81d0b0e2'Michael Niedermayer2014-09-271-30/+67
|\| | | | | | | | | | | | | | | | | | | * commit '1c80c9d7ef809180042257200c7b5f6b81d0b0e2': hwaccel: Call ->get_format again if hwaccel init fails Conflicts: libavcodec/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * hwaccel: Call ->get_format again if hwaccel init failsRémi Denis-Courmont2014-09-261-31/+67
| | | | | | | | | | | | | | This allows the application to fall back on another hwaccel or, more likely, software decoding. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | avcodec/utils: remove avcodec_ prefix for internal symbolClément Bœsch2014-09-141-2/+2
| |
* | Print the actual bit depth for audio if it is different from the sample_fmt ↵Carl Eugen Hoyos2014-09-081-0/+4
| | | | | | | | | | | | bit depth. This is already done for video.
* | Merge commit '9301486408a480629336af4d7fd873c0f28fb2d5'Michael Niedermayer2014-08-281-0/+10
|\| | | | | | | | | | | | | | | | | | | | | | | | | * commit '9301486408a480629336af4d7fd873c0f28fb2d5': avcodec: add stream-level stereo3d side data Conflicts: doc/APIchanges libavcodec/avcodec.h libavcodec/utils.c libavcodec/version.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avcodec: add stream-level stereo3d side dataVittorio Giovara2014-08-281-0/+9
| |
* | avcodec/utils: add GBRP16 to avcodec_align_dimensions2()Michael Niedermayer2014-08-241-0/+2
| | | | | | | | | | | | Fixes Ticket3869 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avfilter: add codecview filterClément Bœsch2014-08-241-0/+6
| |
* | Merge commit '4b1f5e5090abed6c618c8ba380cd7d28d140f867'Michael Niedermayer2014-08-151-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '4b1f5e5090abed6c618c8ba380cd7d28d140f867': cosmetics: Write NULL pointer inequality checks more compactly Conflicts: libavcodec/dvdsubdec.c libavcodec/h263dec.c libavcodec/libxvid.c libavcodec/rv10.c libavcodec/utils.c libavformat/format.c libavformat/matroskadec.c libavformat/segment.c libavutil/opt.c Merged-by: Michael Niedermayer <michaelni@gmx.at>