diff options
author | Anton Khirnov <anton@khirnov.net> | 2011-02-21 21:28:17 +0300 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-02-22 04:44:38 +0300 |
commit | e9eb8d0bcecd656292856698f603a841a82cc9c6 (patch) | |
tree | 4b601393c2f41791e8db8ea2fe4ad2a1dbae3937 /libavformat/wav.c | |
parent | e48fe14a54d8360336dbb22f3f787815b57dda47 (diff) |
avio: avio: avio_ prefixes for put_* functions
In the name of consistency:
put_byte -> avio_w8
put_<type> -> avio_w<type>
put_buffer -> avio_write
put_nbyte will be made private
put_tag will be merged with avio_put_str
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit 77eb5504d3b3e1047900382350e0bc5e0bfb16b5)
Diffstat (limited to 'libavformat/wav.c')
-rw-r--r-- | libavformat/wav.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavformat/wav.c b/libavformat/wav.c index 9a6e7619b6..dea70fa4dc 100644 --- a/libavformat/wav.c +++ b/libavformat/wav.c @@ -43,7 +43,7 @@ static int wav_write_header(AVFormatContext *s) int64_t fmt, fact; put_tag(pb, "RIFF"); - put_le32(pb, 0); /* file length */ + avio_wl32(pb, 0); /* file length */ put_tag(pb, "WAVE"); /* format header */ @@ -59,7 +59,7 @@ static int wav_write_header(AVFormatContext *s) if (s->streams[0]->codec->codec_tag != 0x01 /* hence for all other than PCM */ && !url_is_streamed(s->pb)) { fact = ff_start_tag(pb, "fact"); - put_le32(pb, 0); + avio_wl32(pb, 0); ff_end_tag(pb, fact); } @@ -79,7 +79,7 @@ static int wav_write_packet(AVFormatContext *s, AVPacket *pkt) { AVIOContext *pb = s->pb; WAVContext *wav = s->priv_data; - put_buffer(pb, pkt->data, pkt->size); + avio_write(pb, pkt->data, pkt->size); if(pkt->pts != AV_NOPTS_VALUE) { wav->minpts = FFMIN(wav->minpts, pkt->pts); wav->maxpts = FFMAX(wav->maxpts, pkt->pts); @@ -103,7 +103,7 @@ static int wav_write_trailer(AVFormatContext *s) /* update file size */ file_size = url_ftell(pb); url_fseek(pb, 4, SEEK_SET); - put_le32(pb, (uint32_t)(file_size - 8)); + avio_wl32(pb, (uint32_t)(file_size - 8)); url_fseek(pb, file_size, SEEK_SET); put_flush_packet(pb); @@ -115,7 +115,7 @@ static int wav_write_trailer(AVFormatContext *s) s->streams[0]->codec->sample_rate * (int64_t)s->streams[0]->time_base.num, s->streams[0]->time_base.den); url_fseek(pb, wav->data-12, SEEK_SET); - put_le32(pb, number_of_samples); + avio_wl32(pb, number_of_samples); url_fseek(pb, file_size, SEEK_SET); put_flush_packet(pb); } |