aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/avcodec.h
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-04-08 20:19:12 +0000
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-04-08 20:19:12 +0000
commitfeb993e5794b3dacb51085a9b77013495eb6dd1c (patch)
tree417d93a8a94c57b00b3552393d9355a320c32501 /libavcodec/avcodec.h
parentc81604f862a550bef5261680cfdc48deb6fce046 (diff)
downloadffmpeg-feb993e5794b3dacb51085a9b77013495eb6dd1c.tar.gz
Add av_shrink_packet function for use in av_get_packet that reduces pkt->size
and ensures the following padding is correctly initialized to 0. Originally committed as revision 18378 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r--libavcodec/avcodec.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index 218e236e9b..f500151e85 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -2655,6 +2655,14 @@ void av_init_packet(AVPacket *pkt);
int av_new_packet(AVPacket *pkt, int size);
/**
+ * Reduce packet size, correctly zeroing padding
+ *
+ * @param pkt packet
+ * @param size new size
+ */
+void av_shrink_packet(AVPacket *pkt, int size);
+
+/**
* @warning This is a hack - the packet memory allocation stuff is broken. The
* packet is allocated if it was not really allocated.
*/