[mythtv] ac3 audio problems 0.21-fixes (r16899)

Khanh Tran khanh at khanh.net
Sat Apr 5 02:14:10 UTC 2008


On Fri, Apr 4, 2008 at 6:12 PM, Daniel Chassot <dcha at danielchassot.com> wrote:
>
> On Fri, Apr 4, 2008 at 9:29 PM, Khanh Tran <khanh at khanh.net> wrote:
>  >
>  > On Fri, Apr 4, 2008 at 2:13 PM, Mark Spieth <mark at digivation.com.au> wrote:
>  >  > > > Everything is working great with the upgrade to 0.21-fixes, except AC3
>  >  > > >  audio.  In an avi file or a DVD, the frontend log fills up with:
>  >  > > >
>  >  > > ....
>  >  > > >
>  >  > > >  This only happens with files that have AC3 audio.  Everything else,
>  >  > > >  including live TV and pre-recorded shows works (MP2).  Anyone have any
>  >  > > >  ideas?  I'm seeing this on my various openSUSE frontends (10.0 through
>  >  > > > 10.3).
>  >  > > >  Thanks again for everyone's hard work.
>  >  > >
>  >  > > hello,
>  >  > >
>  >  > > I made some investigations on this exact same problem last weekend and
>  >  > > found the problem and the fix.
>  >  > > The buffering problem comes to the fact that the nuppelvideoplayer
>  >  > > expect audio not being more than 2s away from the video (value 2000 in
>  >  > > the code). It seems that this value is too small for some files
>  >  > > containing AC3 (especially in AVI files).
>  >  > >
>  >  > > To fix the problem, I had to increase this limit from 2000 to 4000 in
>  >  > > the nuppelvideoplayer.cpp file.
>  >  > >
>  >  > > Not that I'm knowing exactly what I'm doing here, but it fixed the
>  >  > > problem. Perhaps some knowledged devloppers can give some insight on
>  >  > > what the right value (tm) should be.
>  >  > >
>  >  > > I will provide you my patch when I get back home.
>  >  > >
>  >  > > Daniel
>  >  >
>  >  > please try the latest patch in 4764. this corrects this.
>  >  > there is also an associated mythmusic patch (if you use mythmusic)
>  >  >
>  >  > mark
>  >
>  >  Running the latest patch from #4764 had some issues (mythtv_ac3.54-v2.patch):
>  >
>  >  1 out of 1 hunk FAILED -- saving rejects to file
>  >  libs/libmyth/audiooutputbase.h.rej
>  >  3 out of 3 hunks FAILED -- saving rejects to file
>  >  libs/libmyth/audiooutputbase.cpp.rej
>  >
>  >  So I had to edit audiooutputbase.h and audiooutputbase.cpp manually,
>  >  but now it wont compile:
>  >
>  >  audiooutputbase.cpp: In member function 'virtual int
>  >  AudioOutputBase::GetAudioBufferedTime() const':
>  >  audiooutputbase.cpp:684: error: passing 'const AudioOutputBase' as
>  >  'this' argument of 'virtual int
>  >  AudioOutputBase::GetAudiotime()' discards qualifiers
>  >  make[2]: *** [audiooutputbase.o] Error 1
>  >  make[2]: Leaving directory
>  >  `/home/mythtv/Documents/download/mythtv-0.21-fixes/mythtv/libs/libmyth'
>  >  make[1]: *** [sub-libmyth] Error 2
>  >  make[1]: Leaving directory
>  >  `/home/mythtv/Documents/download/mythtv-0.21-fixes/mythtv/libs'
>  >  make: *** [sub-libs] Error 2
>  >  mythtv at livingroom:~/Documents/download/mythtv-0.21-fixes/mythtv>
>  >
>  Here is the patch I use on my side.
>  I didn't look at what Mark proposed yet.
>
>  Just to explain a little how I get the value, changing manually the
>  audio sync (via the menu) with a value of 200 ms was getting the thing
>  right. As the sync can be adjusted by 1 sec max in the other
>  direction, I ended up with barely 3.2 s to get something working with
>  my files, then I choose to use 4 in order to have some more margin.
>
>  Hope this helps
>
>  Daniel
>
> _______________________________________________
>  mythtv-dev mailing list
>  mythtv-dev at mythtv.org
>  http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
>
>

Thanks, your patch applies and compiles without issue on -fixes
r16899.  I'm no longer having the audio issues!  Hopefully your "fix"
makes its way into the codebase or the patch in ticket 4764 get
changed to work with more recent revisions.  :)


More information about the mythtv-dev mailing list