Fix problem with EAC3 audio
Jose Alberto Reguero <[email protected]> Mon, 18 Jun 2012 17:24:22 +0200
| Newsgroups | gmane.comp.video.xine.devel |
|---|---|
| Message-ID | <[email protected]> |
This patch fix audio problems whith ffmpeg EAC3 audio. Jose Alberto ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ xine-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/xine-devel
ff_audio_decoder.diff
(text/x-patch, 747 B)
diff -r 748c5603d2df src/combined/ffmpeg/ff_audio_decoder.c
--- a/src/combined/ffmpeg/ff_audio_decoder.c Wed Feb 29 08:35:12 2012 +0200
+++ b/src/combined/ffmpeg/ff_audio_decoder.c Mon Jun 18 17:17:58 2012 +0200
@@ -448,7 +448,8 @@
/* pad input data */
memset(&this->buf[this->size], 0, FF_INPUT_BUFFER_PADDING_SIZE);
- while (this->size>0) {
+ bytes_consumed = 0;
+ while (this->size>bytes_consumed) {
decode_buffer_size = AVCODEC_MAX_AUDIO_FRAME_SIZE;
bytes_consumed =
@@ -555,8 +556,8 @@
offset += bytes_consumed;
}
- /* reset internal accumulation buffer */
- this->size = 0;
+ if (offset)
+ memmove(this->buf, &this->buf[offset], this->size);
}
}
}