summaryrefslogtreecommitdiff
path: root/libavcodec/avcodec.h
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2011-10-08 08:47:47 +0200
committerAnton Khirnov <anton@khirnov.net>2011-10-19 17:02:11 +0200
commitf0eeff708ab5add2d4e8aec9b10683d71b4802be (patch)
tree01a97a9c3d2bd614729377c9f7d7f65a9ad0b198 /libavcodec/avcodec.h
parent84ad31ff180fa089cd6bfd93c246336a16036455 (diff)
lavc: make avcodec_get_context_defaults3 "officially" public
Deprecate avcodec_get_context_defaults/avcodec_get_context_defaults2
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r--libavcodec/avcodec.h16
1 files changed, 14 insertions, 2 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index a8086c6574..c2a3098eeb 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -3592,19 +3592,31 @@ void avcodec_string(char *buf, int buf_size, AVCodecContext *enc, int encode);
*/
const char *av_get_profile_name(const AVCodec *codec, int profile);
+#if FF_API_ALLOC_CONTEXT
/**
* Set the fields of the given AVCodecContext to default values.
*
* @param s The AVCodecContext of which the fields should be set to default values.
+ * @deprecated use avcodec_get_context_defaults3
*/
+attribute_deprecated
void avcodec_get_context_defaults(AVCodecContext *s);
/** THIS FUNCTION IS NOT YET PART OF THE PUBLIC API!
* we WILL change its arguments and name a few times! */
+attribute_deprecated
void avcodec_get_context_defaults2(AVCodecContext *s, enum AVMediaType);
+#endif
-/** THIS FUNCTION IS NOT YET PART OF THE PUBLIC API!
- * we WILL change its arguments and name a few times! */
+/**
+ * Set the fields of the given AVCodecContext to default values corresponding
+ * to the given codec (defaults may be codec-dependent).
+ *
+ * Do not call this function if a non-NULL codec has been passed
+ * to avcodec_alloc_context3() that allocated this AVCodecContext.
+ * If codec is non-NULL, it is illegal to call avcodec_open2() with a
+ * different codec on this AVCodecContext.
+ */
int avcodec_get_context_defaults3(AVCodecContext *s, AVCodec *codec);
#if FF_API_ALLOC_CONTEXT