mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2026-02-04 14:30:55 +08:00
Compilation fixes part 1 patch by (Arvind R. and Burkhard Plaum, plaum, ipf uni-stuttgart de)
Originally committed as revision 4540 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@@ -748,8 +748,13 @@ static int mpegaudio_parse(AVCodecParserContext *s1,
|
||||
}
|
||||
|
||||
#ifdef CONFIG_AC3
|
||||
#ifdef CONFIG_A52BIN
|
||||
extern int ff_a52_syncinfo (AVCodecContext * avctx, const uint8_t * buf,
|
||||
int * flags, int * sample_rate, int * bit_rate);
|
||||
#else
|
||||
extern int a52_syncinfo (const uint8_t * buf, int * flags,
|
||||
int * sample_rate, int * bit_rate);
|
||||
#endif
|
||||
|
||||
typedef struct AC3ParseContext {
|
||||
uint8_t inbuf[4096]; /* input buffer */
|
||||
@@ -796,7 +801,11 @@ static int ac3_parse(AVCodecParserContext *s1,
|
||||
s->inbuf_ptr += len;
|
||||
buf_size -= len;
|
||||
if ((s->inbuf_ptr - s->inbuf) == AC3_HEADER_SIZE) {
|
||||
#ifdef CONFIG_A52BIN
|
||||
len = ff_a52_syncinfo(avctx, s->inbuf, &s->flags, &sample_rate, &bit_rate);
|
||||
#else
|
||||
len = a52_syncinfo(s->inbuf, &s->flags, &sample_rate, &bit_rate);
|
||||
#endif
|
||||
if (len == 0) {
|
||||
/* no sync found : move by one byte (inefficient, but simple!) */
|
||||
memmove(s->inbuf, s->inbuf + 1, AC3_HEADER_SIZE - 1);
|
||||
|
||||
Reference in New Issue
Block a user