aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/vqf.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2011-02-21 16:43:01 +0100
committerRonald S. Bultje <rsbultje@gmail.com>2011-02-21 11:23:22 -0500
commitb7effd4e8338f6ed5bda630ad7ed0809bf458648 (patch)
tree53c878f6dd48c313a9bcde1855c2b4e009822c9e /libavformat/vqf.c
parentf8bed30d8b176fa030f6737765338bb4a2bcabc9 (diff)
downloadffmpeg-b7effd4e8338f6ed5bda630ad7ed0809bf458648.tar.gz
avio: avio_ prefixes for get_* functions
In the name of consistency: get_byte -> avio_r8 get_<type> -> avio_r<type> get_buffer -> avio_read get_partial_buffer will be made private later get_strz is left out becase I want to change it later to return something useful. Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
Diffstat (limited to 'libavformat/vqf.c')
-rw-r--r--libavformat/vqf.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/libavformat/vqf.c b/libavformat/vqf.c
index 9cf0c3a6ad..8a3d170574 100644
--- a/libavformat/vqf.c
+++ b/libavformat/vqf.c
@@ -54,7 +54,7 @@ static void add_metadata(AVFormatContext *s, const char *tag,
buf = av_malloc(len+1);
if (!buf)
return;
- get_buffer(s->pb, buf, len);
+ avio_read(s->pb, buf, len);
buf[len] = 0;
av_metadata_set2(&s->metadata, tag, buf, AV_METADATA_DONT_STRDUP_VAL);
}
@@ -74,7 +74,7 @@ static int vqf_read_header(AVFormatContext *s, AVFormatParameters *ap)
url_fskip(s->pb, 12);
- header_size = get_be32(s->pb);
+ header_size = avio_rb32(s->pb);
st->codec->codec_type = AVMEDIA_TYPE_AUDIO;
st->codec->codec_id = CODEC_ID_TWINVQ;
@@ -82,12 +82,12 @@ static int vqf_read_header(AVFormatContext *s, AVFormatParameters *ap)
do {
int len;
- chunk_tag = get_le32(s->pb);
+ chunk_tag = avio_rl32(s->pb);
if (chunk_tag == MKTAG('D','A','T','A'))
break;
- len = get_be32(s->pb);
+ len = avio_rb32(s->pb);
if ((unsigned) len > INT_MAX/2) {
av_log(s, AV_LOG_ERROR, "Malformed header\n");
@@ -98,9 +98,9 @@ static int vqf_read_header(AVFormatContext *s, AVFormatParameters *ap)
switch(chunk_tag){
case MKTAG('C','O','M','M'):
- st->codec->channels = get_be32(s->pb) + 1;
- read_bitrate = get_be32(s->pb);
- rate_flag = get_be32(s->pb);
+ st->codec->channels = avio_rb32(s->pb) + 1;
+ read_bitrate = avio_rb32(s->pb);
+ rate_flag = avio_rb32(s->pb);
url_fskip(s->pb, len-12);
st->codec->bit_rate = read_bitrate*1000;
@@ -208,7 +208,7 @@ static int vqf_read_packet(AVFormatContext *s, AVPacket *pkt)
pkt->data[0] = 8 - c->remaining_bits; // Number of bits to skip
pkt->data[1] = c->last_frame_bits;
- ret = get_buffer(s->pb, pkt->data+2, size);
+ ret = avio_read(s->pb, pkt->data+2, size);
if (ret<=0) {
av_free_packet(pkt);