summaryrefslogtreecommitdiff
path: root/libavformat/asf.c
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2008-12-18 01:28:29 +0000
committerRonald S. Bultje <rsbultje@gmail.com>2008-12-18 01:28:29 +0000
commit1d217cdb3f4704cd533d7a80a9a30be473ee65b6 (patch)
treeeaa5adc6b8f0d929ea89fa4dee8e5ec8fe3b53dc /libavformat/asf.c
parentd7fb5a18fcf95fa36304b3428628a9cb8d0b5022 (diff)
Make asf_get_packet() and asf_parse_packet() public for use in RTSP-MS and
give them a ff_ prefix. See "[PATCH] asf.c: make functions of interest for MS-RTSP public" thread on ML. Originally committed as revision 16205 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/asf.c')
-rw-r--r--libavformat/asf.c18
1 files changed, 4 insertions, 14 deletions
diff --git a/libavformat/asf.c b/libavformat/asf.c
index 5ff54c782f..1d5c149ea8 100644
--- a/libavformat/asf.c
+++ b/libavformat/asf.c
@@ -555,11 +555,7 @@ static int asf_read_header(AVFormatContext *s, AVFormatParameters *ap)
default: var = defval; break; \
}
-/**
- *
- * @return <0 in case of an error
- */
-static int asf_get_packet(AVFormatContext *s, ByteIOContext *pb)
+int ff_asf_get_packet(AVFormatContext *s, ByteIOContext *pb)
{
ASFContext *asf = s->priv_data;
uint32_t packet_length, padsize;
@@ -703,13 +699,7 @@ static int asf_read_frame_header(AVFormatContext *s, ByteIOContext *pb){
return 0;
}
-/**
- * Parse data from individual ASF packets (which were previously loaded
- * with asf_get_packet()).
- * @returns 0 if data was stored in pkt, <0 on error or 1 if more ASF
- * packets need to be loaded (through asf_get_packet())
- */
-static int asf_parse_packet(AVFormatContext *s, ByteIOContext *pb, AVPacket *pkt)
+int ff_asf_parse_packet(AVFormatContext *s, ByteIOContext *pb, AVPacket *pkt)
{
ASFContext *asf = s->priv_data;
ASFStream *asf_st = 0;
@@ -884,9 +874,9 @@ static int asf_read_packet(AVFormatContext *s, AVPacket *pkt)
int ret;
/* parse cached packets, if any */
- if ((ret = asf_parse_packet(s, s->pb, pkt)) <= 0)
+ if ((ret = ff_asf_parse_packet(s, s->pb, pkt)) <= 0)
return ret;
- if ((ret = asf_get_packet(s, s->pb)) < 0)
+ if ((ret = ff_asf_get_packet(s, s->pb)) < 0)
assert(asf->packet_size_left < FRAME_HEADER_SIZE || asf->packet_segments < 1);
asf->packet_time_start = 0;
}