[FFmpeg-devel] aac_ac3_parser.c bug with splitted headers+ patch
Thu May 15 11:44:52 CEST 2008
With your suggestion the conversion was successful but the parsing of the
aac sampling rate is wrong and the output a/v sync is bad.
Where to upload the sample file to ?
From: ffmpeg-devel-bounces at mplayerhq.hu
[mailto:ffmpeg-devel-bounces at mplayerhq.hu] On Behalf Of Michael Niedermayer
Sent: Wednesday, May 14, 2008 1:01 PM
To: FFmpeg development discussions and patches
Subject: Re: [FFmpeg-devel] aac_ac3_parser.c bug with splitted headers+
On Mon, May 12, 2008 at 12:28:01PM +0200, Nir Drang wrote:
> Here is the attached patch
> -----Original Message-----
> From: ffmpeg-devel-bounces at mplayerhq.hu
> [mailto:ffmpeg-devel-bounces at mplayerhq.hu] On Behalf Of Stefano Sabatini
> Sent: Sunday, May 11, 2008 7:18 PM
> To: ffmpeg-devel at mplayerhq.hu
> Subject: Re: [FFmpeg-devel] aac_ac3_parser.c bug with splitted headers+
> On date Sunday 2008-05-11 20:00:02 +0200, Nir Drang encoded:
> > Hi ,
> > This is my first post so If I have violated any rules regarding posting
> > messages please let me know.
> > I have created a ts file with aac audio and h.264 using a trranscoding
> > from mpeg2+ac3 using ffmpeg .
> > Now when I try to convert the output to mp4 I noticed that the audio
> > rate is wrong and other strange stuff happening.
> > I debugged it and discovered that when the aac header (7 bytes) was
> > cross ts packets there is a bug.
> > In my scenario 6 header bytes were in one ts packet and 1 header byte
> > the second packet.
> > It looked like the code doesn't handle this situation quite well.
> > I have patched it and requesting your comments to my patch , I might
> > broke something else :
Yes, EAC-3 should be broken after the patch, also i do not think it fixes
Could you upload the problematic ac3 in ts file so we could take a look?
(a small part which contains the problematic split frame should be enough)
also could you check if
hdr_info->samples = (rdb + 1) * 1024;
hdr_info->bit_rate = size * 8 * hdr_info->sample_rate /
*need_next_header = 0;
- *new_frame_start = 1;
+ *new_frame_start = 0;
fixed the problem?
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I am the wisest man alive, for I know one thing, and that is that I know
nothing. -- Socrates
More information about the ffmpeg-devel