summaryrefslogtreecommitdiff
path: root/libavcodec/utils.c
Commit message (Collapse)AuthorAge
* lavc: set the default rc_initial_buffer_occupancyLuca Barbato2013-01-15
| | | | | | | | | | | rc_buffer_size is not set before. Solve the initial the rate control underflow issue reported in bug 222. CC: libav-stable@libav.org Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* libavcodec/utils: Add braces to shut up gcc warningsDiego Biurrun2012-12-30
| | | | | libavcodec/utils.c:1050:5: warning: missing braces around initializer [-Wmissing-braces] libavcodec/utils.c:1314:5: warning: missing braces around initializer [-Wmissing-braces]
* lavc: set frame parameters after decoding only if necessaryJanne Grunau2012-12-13
| | | | | | | | Direct rendering capable decoders call get_buffer() which will set the frame parameters. Prevents frames with wrong parameters when a decoder outputs delayed frames after a resolution or pixel format change.
* lavc: factorise setting buffer type in avcodec_default_get_buffer().Anton Khirnov2012-12-04
|
* lavc: don't reuse audio buffersAnton Khirnov2012-12-04
| | | | | Any performance gain from this is negligible and not worth the extra code.
* lavc: set frame properties in ff_get_buffer().Anton Khirnov2012-12-04
| | | | | There is no point in duplicating this code in every get_buffer() implementation.
* lavc: add a wrapper for AVCodecContext.get_buffer().Anton Khirnov2012-12-04
| | | | It will be useful in the upcoming transition to refcounted AVFrames.
* avcodec: remove ff_is_hwaccel_pix_fmtLuca Barbato2012-11-13
| | | | | It is used only in one place and is unlikely it would be needed elsewhere.
* pixdesc: add av_pix_fmt_get_chroma_sub_sampleLuca Barbato2012-11-13
| | | | Deprecate avcodec_get_chroma_sub_sample.
* Include libavutil/channel_layout.h instead of libavutil/audioconvert.hJustin Ruggles2012-11-11
| | | | Also reorder some other #include when applicable.
* decode_audio3: initialize AVFrameIlkka Ollakka2012-11-01
| | | | | | Same fix and issue as in a25d912dca9cd553440167e0476c47581359c0fc Signed-off-by: Anton Khirnov <anton@khirnov.net>
* lavc: check channel count after decoder initJustin Ruggles2012-11-01
| | | | | | Ensures the decoder did not set channel count to an insanely high value during initialization, which could cause large memory usage when it tries to get a buffer during decoding.
* lavc: move SANE_NB_CHANNELS to internal.h and use it in the PCM decodersJustin Ruggles2012-11-01
|
* lavc: initialize output AVFrame before decoding.Anton Khirnov2012-10-24
| | | | | | | Avoids memleaks with audio when extended_data is nontrivial and the user doesn't reset the frame. Shouldn't have any effect for video for now, but might be useful in the future.
* lavc: use the correct API version guard macro for avcodec_encode_audio()Justin Ruggles2012-10-23
|
* avcodec: handle AVERROR_EXPERIMENTALNathan Caldwell2012-10-21
| | | | | | | | | | Error out on init if a codec with CODEC_CAP_EXPERIMENTAL is requested and strict_std_compliance is not FF_COMPLIANCE_EXPERIMENTAL. Move the check from avconv to avcodec_open2() and return AVERROR_EXPERIMENTAL accordingly. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avcodec: prefer decoders without CODEC_CAP_EXPERIMENTALNathan Caldwell2012-10-21
| | | | Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avcodec_encode_audio(): fix invalid freeRafaël Carré2012-10-16
| | | | | | | Since 2bc0de385, AVFrame needs to be initialized before calling avcodec_get_frame_defaults(). Signed-off-by: Anton Khirnov <anton@khirnov.net>
* avutil: Rename ff_set_systematic_pal2() ---> avpriv_set_systematic_pal2()Diego Biurrun2012-10-13
| | | | Functions used across libraries should have avpriv_ and not ff_ prefixes.
* avutil: add yuva422p and yuva444p formatsLuca Barbato2012-10-12
|
* lavc: do not use av_pix_fmt_descriptors directly.Anton Khirnov2012-10-12
|
* avcodec: free extended_data instead address of itJanne Grunau2012-10-09
| | | | Fixes CID732173.
* Restructure av_log_missing_feature messageDiego Biurrun2012-10-09
| | | | | | | | Some invocations include a verb in the log message, others do not. Yet av_log_missing_feature expects callers to provide a verb. Change the function to include a verb instead and update the callers accordingly. The result is a more natural function API and correct English in the function invocations.
* Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormatAnton Khirnov2012-10-08
|
* avcodec: allow either planar or interleaved sample format when encoding monoJustin Ruggles2012-10-07
| | | | | When there is only 1 channel, the planar and interleaved formats of the same data type should be treated as identical.
* avcodec: Drop silly and/or broken printf debug outputDiego Biurrun2012-10-01
|
* lavc: set channel count from channel layout in avcodec_open2().Anton Khirnov2012-09-29
| | | | | Some decoders (e.g. nellymoser) only set channel_layout and do not set channel count.
* avcodec: Drop long-deprecated imgconvert.h headerDiego Biurrun2012-09-27
|
* lavc: add avcodec_free_frame().Anton Khirnov2012-09-24
| | | | | Since an AVFrame now has malloced members (extended_data), it must have a destructor.
* lavc: ensure extended_data is set properly on decodingAnton Khirnov2012-09-24
|
* lavc: initialize AVFrame.extended_data in avcodec_get_frame_defaults()Anton Khirnov2012-09-24
|
* lavc: use av_mallocz to allocate AVFrames.Anton Khirnov2012-09-24
| | | | | Otherwise the frame is uninitialized, so avcodec_get_frame_defaults() cannot determine whether to free extended_data.
* lavc: rename the argument of avcodec_alloc_frame/get_frame_defaultsAnton Khirnov2012-09-24
| | | | | AVFrame is used for both audio and video, so calling the argument 'pic' is misleading.
* avcodec: fix memleak in avcodec_encode_audio2()Justin Ruggles2012-09-22
| | | | Ensure that padded_frame is freed before returning when needed.
* avcodec: cleanup utils.cLuca Barbato2012-09-18
|
* lavc: replace AVCodecContext.encode with subtitle-specific callbackAnton Khirnov2012-09-17
| | | | | AVCodecContext.encode is currently used only for subtitles, encode2 is used for audio and video.
* lavc: add const to private codec class initialization.Anton Khirnov2012-09-17
| | | | Silences a warning about discarding const.
* lavc: add const to AVCodec* function parameters.Anton Khirnov2012-08-18
|
* Replace all CODEC_ID_* with AV_CODEC_ID_*Anton Khirnov2012-08-07
|
* Add support for iLBC decoding/encoding via the external library libilbcMartin Storsjö2012-06-18
| | | | | | The library is 3-clause BSD licensed. Signed-off-by: Martin Storsjö <martin@martin.st>
* avcodec/utils: cast a function argument to shut up a compiler warningDiego Biurrun2012-05-20
| | | | libavcodec/utils.c:251: note: expected ‘const uint8_t *’ but argument is of type ‘const short int *’
* lavc: check that extended_data is properly set in avcodec_encode_audio2().Anton Khirnov2012-05-09
|
* lavc: pad last audio frame with silence when needed.Anton Khirnov2012-05-09
|
* avcodec: do not needlessly set packet size to 0 in avcodec_encode_audio2()Justin Ruggles2012-05-07
| | | | It is already set to 0 by av_free_packet()
* avcodec: for audio encoding, reset output packet when it is not validJustin Ruggles2012-05-07
|
* avcodec: refactor avcodec_encode_audio2() to merge common branchesJustin Ruggles2012-05-07
|
* avcodec: remove fallbacks for AVCodec.encode() in avcodec_encode_audio2()Justin Ruggles2012-05-07
| | | | We no longer have any audio encoders using AVCodec.encode().
* lavc: add sample rate and channel layout to AVFrame.Anton Khirnov2012-05-07
| | | | Rationale is the same as for video width/height etc.
* Remove lowres video decodingMans Rullgard2012-04-21
| | | | | | | This feature is complex, of questionable utility, and slows down normal decoding. Signed-off-by: Mans Rullgard <mans@mansr.com>
* avcodec_string: Favor AVCodecContext.codec over the default codec.Alex Converse2012-04-17
| | | | This improves output for formats with more than one AVCodec.