aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/options.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2011-06-18 13:40:48 +0200
committerAnton Khirnov <anton@khirnov.net>2011-07-10 17:09:28 +0200
commit71a861cf4010ab835fab383a250f27903eb61a34 (patch)
tree5af1c2668613d3cd606b9803f34ac68c22152228 /libavcodec/options.c
parent18c007ba37b2c7dee5bd2f1a3eb3bfee9b6b3d26 (diff)
downloadffmpeg-71a861cf4010ab835fab383a250f27903eb61a34.tar.gz
lavc: make avcodec_alloc_context3 officially public.
Deprecate avcodec_alloc_context/2.
Diffstat (limited to 'libavcodec/options.c')
-rw-r--r--libavcodec/options.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/options.c b/libavcodec/options.c
index a876ce0404..1e7fe522ea 100644
--- a/libavcodec/options.c
+++ b/libavcodec/options.c
@@ -540,6 +540,7 @@ AVCodecContext *avcodec_alloc_context3(AVCodec *codec){
return avctx;
}
+#if FF_API_ALLOC_CONTEXT
AVCodecContext *avcodec_alloc_context2(enum AVMediaType codec_type){
AVCodecContext *avctx= av_malloc(sizeof(AVCodecContext));
@@ -549,14 +550,17 @@ AVCodecContext *avcodec_alloc_context2(enum AVMediaType codec_type){
return avctx;
}
+#endif
void avcodec_get_context_defaults(AVCodecContext *s){
avcodec_get_context_defaults2(s, AVMEDIA_TYPE_UNKNOWN);
}
+#if FF_API_ALLOC_CONTEXT
AVCodecContext *avcodec_alloc_context(void){
return avcodec_alloc_context2(AVMEDIA_TYPE_UNKNOWN);
}
+#endif
int avcodec_copy_context(AVCodecContext *dest, const AVCodecContext *src)
{