[mythtv-users] ac3 passthrough problems
Scott
list-mythtv at bluecamel.eml.cc
Thu Sep 21 19:36:05 UTC 2006
On Sep 21, 2006, at 2:17 AM, Thomas Börkel wrote:
>> With the config shown above, I get a nasty stuttering sound that
>> might
>> sound like a helicopter whirling it's blades :) If I do not check the
>> "enable AC3/DTS passthrough" options then I get normal sounding audio
>> but not DD or DTS format. My receiver says I'm instead receiving a
>> PCM
>> 48kHz signal from the SPDIF. Using mplayer on the same test clip
>> shows
>> DD 5.1 with the -afm hwac3 pass through option.
>
> Apparently, Myth sends raw AC3 data to Alsa and Alsa does not switch
> your receiver to DD.
Not necessarily. It's perfectly possible to send analog format
signals out the spdif and for the receiver to decode them. Again,
with the -afm hwac3 option, mplayer sends the raw AC3 sound track out
to alsa and my receiver does decode it correctly. This is easily seen
by running "mplayer -v -ao alsa -afm hwac3 dvd://1" Note that you
would think that the alsa default device gets used here but mplayer
is smarter than that. Instead it uses the iec958 (aka spdif) of my
sound card. This all works regardless of if I'm using an asoundrc
file or not.
> I have wrestled with this for several days and now it works. Try this:
> First throw away your .asoundrc and restart mythfrontend.
Gladly :)
> Set this in Myth:
> Normal device: ALSA:default
> Passthrough device: ALSA:spdif
> AC3 passthrough: Checked
>
> With these settings, you should:
> - get DS sound for MP2 and AC3 2.0
> - get DD sound for AC3 5.1
So, with no asoundrc file in place, I changed my MythTV setting to
reflect what you wrote. Here the are:
Audio output device: ALSA:default
Passthrough output device: ALSA:spdif
Enable AC3 to SPDIF passthrough: [checked]
Enable DTS to SPDIF passthrough: [not checked]
Aggressive Sound card Buffering: [not checked]
Use internal volume controls: [not checked]
The options for mixer and pcm aren't available because Use Internal
volume controls was not checked. With this config audio from MythTV
makes a nasty stuttering sound that might sound similar helicopter
blades or such. If I uncheck "enable AC3 to SPDIF" then I get normal
sound but it's not DD. It comes through as PCM 48kHz which I think is
just an analog format.
I tested this using "-v audio" and attached an audio.debug file.
Looking at the log, why does MythTV detect the audio twice? Is this
expected?
2006-09-21 15:20:36.529 AFD: Opened codec 0x82ed910, id(MPEG2VIDEO)
type(Video)
2006-09-21 15:20:36.529 AFD: Opened codec 0x834d580, id(AC3) type(Audio)
2006-09-21 15:20:36.529 AFD: Audio Track #1 is A/V stream #1 and has
6 channels in the English language(6647399).
2006-09-21 15:20:36.529 AFD: Selected track 1: English AC3 5.1ch (A/V
Stream #1)
2006-09-21 15:20:36.529 AFD: Initializing audio parms from audio
track #1
2006-09-21 15:20:36.529 AFD: Audio format changed
from id(NONE) -1Hz -1ch 0bps ; id(NONE) -1Hz -1ch 0bps
to id( AC3) 48000Hz 6ch 16bps pt ; id( AC3) 48000Hz 2ch
16bps pt
2006-09-21 15:20:38.012 TV: Attempting to change from None to
WatchingPreRecorded
0: start_time: 7715.966 duration: 323.686
1: start_time: 7715.929 duration: 323.698
stream: start_time: 85732.539 duration: 3596.929 bitrate=15960 kb/s
2006-09-21 15:20:38.056 AFD: Opened codec 0x83a6cc0, id(MPEG2VIDEO)
type(Video)
2006-09-21 15:20:38.056 AFD: Opened codec 0x83a72c0, id(AC3) type(Audio)
2006-09-21 15:20:38.057 AFD: Audio Track #1 is A/V stream #1 and has
5 channels in the English language(6647399).
2006-09-21 15:20:38.057 AFD: Selected track 1: English AC3 5ch (A/V
Stream #1)
2006-09-21 15:20:38.057 AFD: Initializing audio parms from audio
track #1
2006-09-21 15:20:38.057 AFD: Audio format changed
from id(NONE) -1Hz -1ch 0bps ; id(NONE) -1Hz -1ch 0bps
to id( AC3) 48000Hz 5ch 16bps pt ; id( AC3) 48000Hz 2ch
16bps pt
2006-09-21 15:20:38.058 AO: Killing AudioOutputDSP
2006-09-21 15:20:38.058 Opening ALSA audio device 'spdif'.
2006-09-21 15:20:38.062 in SetParameters(format=2, channels=2,
rate=48000, buffer_time=500000, period_time=125000)
2006-09-21 15:20:38.062 get_buffer_size returned 16384
2006-09-21 15:20:38.062 set_period_time_near returned 170666
2006-09-21 15:20:38.062 get_period_size returned 8192
2006-09-21 15:20:38.098 AO: Audio fragment size: 6144
2006-09-21 15:20:38.099 AO: Audio Stretch Factor: 1
2006-09-21 15:20:38.099 AO: Ending reconfigure
2006-09-21 15:20:38.099 AO: kickoffOutputAudioLoop: pid = 24504
2006-09-21 15:20:38.099 AO: OutputAudioLoop: Play Event
> Also, for AC3 5.1 working, you have to switch OFF "Use video as
> timebase" in the frontend/tv/playback settings.
Confirmed this setting is off before I tested the above.
The help is much appreciated. I'm really at the end of my rope on
this one. What is so frustrating is seeing both xine and mplayer pass
the AC3 correctly but having MythTV fail on the same exact sources.
--
Scott
-------------- next part --------------
A non-text attachment was scrubbed...
Name: audio.debug.gz
Type: application/x-gzip
Size: 2278 bytes
Desc: not available
Url : http://mythtv.org/pipermail/mythtv-users/attachments/20060921/cb65f9ec/attachment.bin
More information about the mythtv-users
mailing list