summaryrefslogtreecommitdiff
path: root/libavutil/frame.h
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2014-02-11 14:15:20 +0100
committerAnton Khirnov <anton@khirnov.net>2014-02-24 07:25:07 +0100
commit1155fd02ae7bac215acab316e847c6bb25f74fc3 (patch)
treeed275ea172505fe236d353a17c618a32a6bff5c0 /libavutil/frame.h
parent746dca483a2f0f2639265f6e1c0085c8861875a1 (diff)
frame: add a convenience function for copying AVFrame data
Diffstat (limited to 'libavutil/frame.h')
-rw-r--r--libavutil/frame.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/libavutil/frame.h b/libavutil/frame.h
index 20766423f5..30cc1e47c9 100644
--- a/libavutil/frame.h
+++ b/libavutil/frame.h
@@ -506,6 +506,19 @@ int av_frame_is_writable(AVFrame *frame);
int av_frame_make_writable(AVFrame *frame);
/**
+ * Copy the frame data from src to dst.
+ *
+ * This function does not allocate anything, dst must be already initialized and
+ * allocated with the same parameters as src.
+ *
+ * This function only copies the frame data (i.e. the contents of the data /
+ * extended data arrays), not any other properties.
+ *
+ * @return >= 0 on success, a negative AVERROR on error.
+ */
+int av_frame_copy(AVFrame *dst, const AVFrame *src);
+
+/**
* Copy only "metadata" fields from src to dst.
*
* Metadata for the purpose of this function are those fields that do not affect