diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2013-01-04 23:52:57 +0400 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2013-01-04 23:52:57 +0400 |
commit | f2214c622458dc9963f775a9406174c994328405 (patch) | |
tree | 9486c1c2f95c77fe5b5ae2705eba43018a01563f /libavformat/au.c | |
parent | d885cc41e526284a1534e8c689175fe6ffba60e0 (diff) |
au: use ff_raw_write_packet()
Diffstat (limited to 'libavformat/au.c')
-rw-r--r-- | libavformat/au.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/libavformat/au.c b/libavformat/au.c index 4cf896688b..2e54a185ff 100644 --- a/libavformat/au.c +++ b/libavformat/au.c @@ -135,6 +135,8 @@ AVInputFormat ff_au_demuxer = { #if CONFIG_AU_MUXER +#include "rawenc.h" + /* AUDIO_FILE header */ static int put_au_header(AVIOContext *pb, AVCodecContext *enc) { @@ -164,13 +166,6 @@ static int au_write_header(AVFormatContext *s) return 0; } -static int au_write_packet(AVFormatContext *s, AVPacket *pkt) -{ - AVIOContext *pb = s->pb; - avio_write(pb, pkt->data, pkt->size); - return 0; -} - static int au_write_trailer(AVFormatContext *s) { AVIOContext *pb = s->pb; @@ -196,7 +191,7 @@ AVOutputFormat ff_au_muxer = { .audio_codec = AV_CODEC_ID_PCM_S16BE, .video_codec = AV_CODEC_ID_NONE, .write_header = au_write_header, - .write_packet = au_write_packet, + .write_packet = ff_raw_write_packet, .write_trailer = au_write_trailer, .codec_tag = (const AVCodecTag* const []){ codec_au_tags, 0 }, }; |