mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2025-10-22 08:31:07 +08:00
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
This commit is contained in:
@@ -2654,6 +2654,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.
|
||||
|
Reference in New Issue
Block a user