summaryrefslogtreecommitdiff
path: root/libavformat/dv.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/dv.c
parentf8bed30d8b176fa030f6737765338bb4a2bcabc9 (diff)
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/dv.c')
-rw-r--r--libavformat/dv.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libavformat/dv.c b/libavformat/dv.c
index 1f05eb2d44..0598607ff4 100644
--- a/libavformat/dv.c
+++ b/libavformat/dv.c
@@ -410,7 +410,7 @@ static int dv_read_header(AVFormatContext *s,
if (!c->dv_demux)
return -1;
- state = get_be32(s->pb);
+ state = avio_rb32(s->pb);
while ((state & 0xffffff7f) != 0x1f07003f) {
if (url_feof(s->pb)) {
av_log(s, AV_LOG_ERROR, "Cannot find DV header.\n");
@@ -420,14 +420,14 @@ static int dv_read_header(AVFormatContext *s,
marker_pos = url_ftell(s->pb);
if (state == 0xff3f0701 && url_ftell(s->pb) - marker_pos == 80) {
url_fseek(s->pb, -163, SEEK_CUR);
- state = get_be32(s->pb);
+ state = avio_rb32(s->pb);
break;
}
- state = (state << 8) | get_byte(s->pb);
+ state = (state << 8) | avio_r8(s->pb);
}
AV_WB32(c->buf, state);
- if (get_buffer(s->pb, c->buf + 4, DV_PROFILE_BYTES - 4) <= 0 ||
+ if (avio_read(s->pb, c->buf + 4, DV_PROFILE_BYTES - 4) <= 0 ||
url_fseek(s->pb, -DV_PROFILE_BYTES, SEEK_CUR) < 0)
return AVERROR(EIO);
@@ -455,7 +455,7 @@ static int dv_read_packet(AVFormatContext *s, AVPacket *pkt)
if (!c->dv_demux->sys)
return AVERROR(EIO);
size = c->dv_demux->sys->frame_size;
- if (get_buffer(s->pb, c->buf, size) <= 0)
+ if (avio_read(s->pb, c->buf, size) <= 0)
return AVERROR(EIO);
size = dv_produce_packet(c->dv_demux, pkt, c->buf, size);