summaryrefslogtreecommitdiff
path: root/libavcodec/avcodec.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-05-01 18:33:30 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-05-01 18:33:30 +0200
commit67731ef40f9f86ca870ae4c5dbbe01ead8dba962 (patch)
tree3e9a27bf178e0dc354322a74ac09485ca8ca4721 /libavcodec/avcodec.h
parenta5ba4e186bcb44c60f215e1367e3d5269b564cea (diff)
parentaf8a47905a3fa349a68841fac76b461b305c5efe (diff)
Merge remote-tracking branch 'qatar/master'
* qatar/master: avutil: doxy: Small clarification for av_buffer_create() avcodec: doxy: Clarify how to use buf[] when implementing get_buffer2() avcodec: doxy: Clarify what get_buffer2 must fill in buf[] Conflicts: libavutil/buffer.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r--libavcodec/avcodec.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index e5b0c2b176..d18b4347db 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -2042,8 +2042,10 @@ typedef struct AVCodecContext {
/**
* This callback is called at the beginning of each frame to get data
* buffer(s) for it. There may be one contiguous buffer for all the data or
- * there may be a buffer per each data plane or anything in between. Each
- * buffer must be reference-counted using the AVBuffer API.
+ * there may be a buffer per each data plane or anything in between. What
+ * this means is, you may set however many entries in buf[] you feel necessary.
+ * Each buffer must be reference-counted using the AVBuffer API (see description
+ * of buf[] below).
*
* The following fields will be set in the frame before this callback is
* called:
@@ -2064,8 +2066,11 @@ typedef struct AVCodecContext {
* extended_data must be allocated with av_malloc() and will be freed in
* av_frame_unref().
* * otherwise exended_data must point to data
- * - buf[] must contain references to the buffers that contain the frame
- * data.
+ * - buf[] must contain one or more pointers to AVBufferRef structures. Each of
+ * the frame's data and extended_data pointers must be contained in these. That
+ * is, one AVBufferRef for each allocated chunk of memory, not necessarily one
+ * AVBufferRef per data[] entry. See: av_buffer_create(), av_buffer_alloc(),
+ * and av_buffer_ref().
* - extended_buf and nb_extended_buf must be allocated with av_malloc() by
* this callback and filled with the extra buffers if there are more
* buffers than buf[] can hold. extended_buf will be freed in