diff options
author | Anton Khirnov <anton@khirnov.net> | 2011-02-21 19:28:17 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-02-22 02:44:38 +0100 |
commit | e9eb8d0bcecd656292856698f603a841a82cc9c6 (patch) | |
tree | 4b601393c2f41791e8db8ea2fe4ad2a1dbae3937 /libavformat/oggenc.c | |
parent | e48fe14a54d8360336dbb22f3f787815b57dda47 (diff) | |
download | ffmpeg-e9eb8d0bcecd656292856698f603a841a82cc9c6.tar.gz |
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/oggenc.c')
-rw-r--r-- | libavformat/oggenc.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/libavformat/oggenc.c b/libavformat/oggenc.c index 79e4a8aa90..533f89e7b8 100644 --- a/libavformat/oggenc.c +++ b/libavformat/oggenc.c @@ -69,7 +69,7 @@ static void ogg_update_checksum(AVFormatContext *s, AVIOContext *pb, int64_t crc int64_t pos = url_ftell(pb); uint32_t checksum = get_checksum(pb); url_fseek(pb, crc_offset, SEEK_SET); - put_be32(pb, checksum); + avio_wb32(pb, checksum); url_fseek(pb, pos, SEEK_SET); } @@ -86,16 +86,16 @@ static int ogg_write_page(AVFormatContext *s, OGGPage *page, int extra_flags) return ret; init_checksum(pb, ff_crc04C11DB7_update, 0); put_tag(pb, "OggS"); - put_byte(pb, 0); - put_byte(pb, page->flags | extra_flags); - put_le64(pb, page->granule); - put_le32(pb, oggstream->serial_num); - put_le32(pb, oggstream->page_counter++); + avio_w8(pb, 0); + avio_w8(pb, page->flags | extra_flags); + avio_wl64(pb, page->granule); + avio_wl32(pb, oggstream->serial_num); + avio_wl32(pb, oggstream->page_counter++); crc_offset = url_ftell(pb); - put_le32(pb, 0); // crc - put_byte(pb, page->segments_count); - put_buffer(pb, page->segments, page->segments_count); - put_buffer(pb, page->data, page->size); + avio_wl32(pb, 0); // crc + avio_w8(pb, page->segments_count); + avio_write(pb, page->segments, page->segments_count); + avio_write(pb, page->data, page->size); ogg_update_checksum(s, pb, crc_offset); put_flush_packet(pb); @@ -104,7 +104,7 @@ static int ogg_write_page(AVFormatContext *s, OGGPage *page, int extra_flags) if (size < 0) return size; - put_buffer(s->pb, buf, size); + avio_write(s->pb, buf, size); put_flush_packet(s->pb); av_free(buf); oggstream->page_count--; |