diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2008-03-23 18:43:29 +0300 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2008-03-23 18:43:29 +0300 |
commit | c599e297e714b572e1bea2f4e59c319dce13b174 (patch) | |
tree | ec77afb8956ddb004532847b0908f5c645eb6592 /libavcodec/ac3_parser.c | |
parent | 721392606bafd5a6971cce2d93fe5d0bc2a76927 (diff) |
Pass AACAC3ParseContext to sync() instead of individual arguments. Patch by
Bartlomiej Wolowiec (bartek wolowiec gmail com)
Originally committed as revision 12564 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ac3_parser.c')
-rw-r--r-- | libavcodec/ac3_parser.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/libavcodec/ac3_parser.c b/libavcodec/ac3_parser.c index bae788ed49..0a8c804e0a 100644 --- a/libavcodec/ac3_parser.c +++ b/libavcodec/ac3_parser.c @@ -119,21 +119,20 @@ int ff_ac3_parse_header(const uint8_t buf[7], AC3HeaderInfo *hdr) return 0; } -static int ac3_sync(const uint8_t *buf, int *channels, int *sample_rate, - int *bit_rate, int *samples) +static int ac3_sync(AACAC3ParseContext *hdr_info) { int err; AC3HeaderInfo hdr; - err = ff_ac3_parse_header(buf, &hdr); + err = ff_ac3_parse_header(hdr_info->inbuf, &hdr); if(err < 0) return 0; - *sample_rate = hdr.sample_rate; - *bit_rate = hdr.bit_rate; - *channels = hdr.channels; - *samples = AC3_FRAME_SIZE; + hdr_info->sample_rate = hdr.sample_rate; + hdr_info->bit_rate = hdr.bit_rate; + hdr_info->channels = hdr.channels; + hdr_info->samples = AC3_FRAME_SIZE; return hdr.frame_size; } |