summaryrefslogtreecommitdiff
path: root/libavformat/mtv.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/mtv.c')
-rw-r--r--libavformat/mtv.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/libavformat/mtv.c b/libavformat/mtv.c
index d6f8a2018b..94d8aff548 100644
--- a/libavformat/mtv.c
+++ b/libavformat/mtv.c
@@ -84,16 +84,16 @@ static int mtv_read_header(AVFormatContext *s, AVFormatParameters *ap)
unsigned int audio_subsegments;
url_fskip(pb, 3);
- mtv->file_size = get_le32(pb);
- mtv->segments = get_le32(pb);
+ mtv->file_size = avio_rl32(pb);
+ mtv->segments = avio_rl32(pb);
url_fskip(pb, 32);
- mtv->audio_identifier = get_le24(pb);
- mtv->audio_br = get_le16(pb);
- mtv->img_colorfmt = get_le24(pb);
- mtv->img_bpp = get_byte(pb);
- mtv->img_width = get_le16(pb);
- mtv->img_height = get_le16(pb);
- mtv->img_segment_size = get_le16(pb);
+ mtv->audio_identifier = avio_rl24(pb);
+ mtv->audio_br = avio_rl16(pb);
+ mtv->img_colorfmt = avio_rl24(pb);
+ mtv->img_bpp = avio_r8(pb);
+ mtv->img_width = avio_rl16(pb);
+ mtv->img_height = avio_rl16(pb);
+ mtv->img_segment_size = avio_rl16(pb);
/* Calculate width and height if missing from header */
@@ -106,7 +106,7 @@ static int mtv_read_header(AVFormatContext *s, AVFormatParameters *ap)
/ mtv->img_width;
url_fskip(pb, 4);
- audio_subsegments = get_le16(pb);
+ audio_subsegments = avio_rl16(pb);
mtv->full_segment_size =
audio_subsegments * (MTV_AUDIO_PADDING_SIZE + MTV_ASUBCHUNK_DATA_SIZE) +
mtv->img_segment_size;