[mythtv-users] Simultaneous analogue (analog) and S/PDIF output

Alex Butcher mythlist at assursys.co.uk
Fri Jan 14 15:04:26 UTC 2011


On Sat, 15 Jan 2011, Jean-Yves Avenard wrote:

> On 14 January 2011 22:42, Alex Butcher <mythlist at assursys.co.uk> wrote:
>> Ideally, I'd like MythTV and ALSA combined to do what my PS2, XBox and cheap
>> DVD player can do easily; output sensible analogue stereo at all times (I
>> don't really care which combination of channels they use to generate the
>> stereo pair when playing >2 channel soundtracks unless it can also be
>> tweaked /as the content is playing/), and output PCM 2.0, Dolby Digital 2.0,
>> 5.0, 5.1 or DTS over digital when any of those types of soundtracks are
>> selected by the user.  Maybe some kind of advanced manual channel mapping
>> for too, but that would just be making MythTV /better/ than appliances!
>
> I know a cheap DVD player or STB receiver can do that.. But myth
> can't. It can only handle one output at a time unfortunately. You can
> play with the alsa configuration to simulate simultaneous output, but
> ultimately myth can not output the digital DTS/AC3 stream while also
> decoding it and outputting the decoded version.
>
> The mythtv player has never been designed to do it, and its
> architecture is fundamentally not design to handle it.

My original expectation was that MythTV would read the audio data and,
process for its default output AND, if so configured, pass the original raw
stream onto the PassThruDevice. I imagine the cheap appliances must do
something similar to be able to do what they do.

Since you mentioned in the closing line of your last message that there was
only one stream, it all becomes clear.

> the issue isn't trivial either

...sad, but understandable.

[...]

> If you want to easily achieve what you are looking for, you are better
> off getting a hdmi amplifier ; now there you can completely remove
> AC3/DTS digital audio and let myth decode everything and send LPCM
> only. From there it's easy to configure alsa to mix the output to two
> different devices.

Yup, at some point, I can see a big HD upgrade including at least my TV and
receiver.  I can see it'll probably tidy quite a few things up, and I can
switch to using my GT240 and HDMI instead of using my homebrew VGA-to-RGB
SCART adaptor too.

[...]

>> That must be a MythTV (0.24-fixes vs your tree or -trunk?) limitation then,
>> as doing
>>
>> wget \
>> "http://www.lynnepublishing.com/surround/www_lynnemusic_com_surround_test.ac3"
>>
>> mplayer -ao alsa:device=iec958 -ac hwac3
>> www_lynnemusic_com_surround_test.ac3
>
> but there you only output to the digital device.
> not analog *and* digital at the same time, so how is this comparison relevant?

In the context of my original belief that MythTV would have a processed
analogue stream and the original stream, I expected it to be able to do the
same thing.

[...]

> you main problem is that you are starring at a wall saying very loudly
> there's a door, when there's none.
> turning around, jumping, repainting the wall, looking at it upside
> down etc.. will never change the fact that there is no door; no matter
> how long you try for.

Not so much saying very loudly that there's a door, as expecting there to be
a door, reading various hints that there's a door, but being unable to find
it! Now I know there's no door, I can stop looking for it. :-)

> So this is my last message on this topic. There is no bug in myth, it
> is behaving exactly as designed.

I guess this was what I was grasping at with my UI sketch in my last
message.  But of course, it's more than just a "simple matter of writing the
code" and the syncing makes it even more difficult to address.

> Get a cheap STB or DVD player, it will do just what you want to do.

...apart from all the /other/ things that MythTV does so much better than
any appliance. I can live with this minor deficiency.  :-)

To be fair, I suspect all this stuff probably ought to be resolved at the
ALSA layer (e.g.  by having the standard sound API require apps send E-AC-3
or something to ALSA), but it isn't, so we have to make do with what we
have.  Oh well, there's the opportunity for the next Linux sound system
re-write.  :-)

Thanks for your explanations.

Best Regards,
Alex


More information about the mythtv-users mailing list