Commit a3436ee3 authored by ramiro's avatar ramiro

Export av_init_packet

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@9211 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent f9c6ff35
...@@ -57,16 +57,7 @@ void av_destruct_packet_nofree(AVPacket *pkt); ...@@ -57,16 +57,7 @@ void av_destruct_packet_nofree(AVPacket *pkt);
void av_destruct_packet(AVPacket *pkt); void av_destruct_packet(AVPacket *pkt);
/* initialize optional fields of a packet */ /* initialize optional fields of a packet */
static inline void av_init_packet(AVPacket *pkt) void av_init_packet(AVPacket *pkt);
{
pkt->pts = AV_NOPTS_VALUE;
pkt->dts = AV_NOPTS_VALUE;
pkt->pos = -1;
pkt->duration = 0;
pkt->flags = 0;
pkt->stream_index = 0;
pkt->destruct= av_destruct_packet_nofree;
}
/** /**
* Allocate the payload of a packet and intialized its fields to default values. * Allocate the payload of a packet and intialized its fields to default values.
......
...@@ -176,6 +176,17 @@ void av_destruct_packet(AVPacket *pkt) ...@@ -176,6 +176,17 @@ void av_destruct_packet(AVPacket *pkt)
pkt->data = NULL; pkt->size = 0; pkt->data = NULL; pkt->size = 0;
} }
void av_init_packet(AVPacket *pkt)
{
pkt->pts = AV_NOPTS_VALUE;
pkt->dts = AV_NOPTS_VALUE;
pkt->pos = -1;
pkt->duration = 0;
pkt->flags = 0;
pkt->stream_index = 0;
pkt->destruct= av_destruct_packet_nofree;
}
int av_new_packet(AVPacket *pkt, int size) int av_new_packet(AVPacket *pkt, int size)
{ {
uint8_t *data; uint8_t *data;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment