[mythtv] [PATCH] Big DVB Patch V3.5 - MPEG TS

Mark Anderson markjanderson at mail.com
Tue Jan 11 04:27:55 EST 2005

On Tue, 11 Jan 2005 08:06 pm, Tim Davies wrote:
> Okay, I've been at it again.
> A few changes to get AC3 working properly in Australia, using the transport
> stream.
> -          siparser.cpp and dvbrecorder.cpp now insert *all* descriptors
> from the PMT, not just the first
> -          mpegts.c looks for AC3 data in the private stream, and then
> treats it as AC3 data
Does this rely on the hacked mpeg.c from the original patch?

> Mark - I had to remove a small portion of your patch to get this to fly
> (the last hunk in my patch).  It was trying to change audio tracks at every
> packet, and made for some interesting sound effects!
That piece of code was a bit of trickery to get the audio to switch from mpeg 
to AC3 when the stream changed. As far as I understand there is only one data 
stream but two "logical" tracks are created in avformat decoder, one for mpeg 
and one fro AC3, the audio needs to be re-initialise when the data stream 
changes type. I should have actually used setCurrentAudioTrack after looking 
up the audio track for the codec, but I was being lazy. I think with that 
line removed you wont be able to switch between ac3 and mpeg stations.

> I was wondering if the audio track selection code in your patch was
> actually doing much (for your setup).  I'm recording the TS so I get all
> audio tracks, but you should only be getting one recorded based on
> SetDemuxFilters in dvbrecorder.cpp.  That would make the choice rather
> simple.
No, once you have selected an mpeg and an ac3 station you get two tracks
> Anyway, apart from that small change, the audio track selection code seems
> to do the trick.
I am keen to look at this once I get the bloody transport.c thing worked out, 
which I think I have the solution to but am still testing at the moment.

> Tim.

More information about the mythtv-dev mailing list