summaryrefslogtreecommitdiff
path: root/libavcodec/ac3_parser.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2008-04-19 01:50:40 +0000
committerMichael Niedermayer <michaelni@gmx.at>2008-04-19 01:50:40 +0000
commit454064ad1eb39ffbea4906dbe2e246e18a5d5d67 (patch)
treed61c90f42b93b89da1d61de46295e39d26afdedd /libavcodec/ac3_parser.c
parentbf237413f31ceb4a147c064e5693468b6c9c2a10 (diff)
downloadffmpeg-454064ad1eb39ffbea4906dbe2e246e18a5d5d67.tar.gz
Change aac and ac3 parsers to use ff_combine_frame().
Originally committed as revision 12894 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ac3_parser.c')
-rw-r--r--libavcodec/ac3_parser.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/ac3_parser.c b/libavcodec/ac3_parser.c
index bc728c19da..511223398c 100644
--- a/libavcodec/ac3_parser.c
+++ b/libavcodec/ac3_parser.c
@@ -123,12 +123,13 @@ int ff_ac3_parse_header(const uint8_t buf[7], AC3HeaderInfo *hdr)
return 0;
}
-static int ac3_sync(AACAC3ParseContext *hdr_info)
+static int ac3_sync(uint64_t state, AACAC3ParseContext *hdr_info)
{
int err;
+ uint64_t tmp = be2me_64(state);
AC3HeaderInfo hdr;
- err = ff_ac3_parse_header(hdr_info->inbuf, &hdr);
+ err = ff_ac3_parse_header(((uint8_t *)&tmp)+8-AC3_HEADER_SIZE, &hdr);
if(err < 0)
return 0;
@@ -144,7 +145,6 @@ static int ac3_sync(AACAC3ParseContext *hdr_info)
static av_cold int ac3_parse_init(AVCodecParserContext *s1)
{
AACAC3ParseContext *s = s1->priv_data;
- s->inbuf_ptr = s->inbuf;
s->header_size = AC3_HEADER_SIZE;
s->sync = ac3_sync;
return 0;