I have seen a few people post methods about enabling AC3 passthrough, and many of them are overly complicated or in some cases even wrong. This also serves as the first place to describe how to enable DTS passthrough. Since I designed the code that actually does this, I’ll list the steps here:
Note: This does not work with all receivers. If these instructions fail for you, most likely your receiver will not work with this. Passthrough is still a hack, and thus this hack is still outside of the specs.
Note 2: Apple broke AC3 rather seriously in QT 7.3 (bug id 5594478, go tell them to fix it). If have a .mov file, open it, and it says that it is stereo audio rather than 5.1, this is a symptom of that bug. You will need to have at least Perian 1.1 and re-open the original file that made the .mov file. This bug has been fixed in 7.4.5, but any .mov files created with QT 7.3 or 7.4 are still affected by this bug.
Note 3: Perian 1.1.4 contains a bug in which DTS passthrough fails to work. This will be fixed in the next version. This has been fixed in Perian 1.2, released Dec 17, 2009.
-
Install Perian Just go to Perian.org and click the big download link. Double click on the pref pane, and it’ll install itself.
-
Connect your receiver The audio connection must be a digital connection. In all cases that I know of, this means an optical cable from your mac to the receiver. In the case of the AppleTV, this is certainly the case. I suppose this could work with the coaxial digital connection, but I don’t know of the audio hardware that provides this connection.
-
Change the sample rate to 48KHz
- On the mac, open
/Applications/Utilities/AudioMidiSetup.app
- In the lower right, change the format to
48000.0 Hz
, and2ch-16bit
Audio Midi Setup Screenshot
Note: If, in the off situation, you are playing a file with 44.1KHz audio, you will need to set it to44100.0 Hz
instead. - On the AppleTV, this is much more difficult. I recommend using Sapphire instead for playback. It’ll do this step for you
- On the mac, open
-
Enable AC3/DTS passthrough. This is easy when done correctly. For AC3 passthrough, open
/Applications/Utilities/Terminal.app
and typedefaults write com.cod3r.a52codec attemptPassthrough 1
To turn off AC3 passthrough, you type this instead:
defaults delete com.cod3r.a52codec attemptPassthrough
DTS passthrough is done through:
defaults write org.perian.Perian attemptDTSPassthrough 1
To turn off DTS passthrough, you type this instead:
defaults delete org.perian.Perian attemptDTSPassthrough
-
Launch your application to play with passthrough. This means if it was already running, quit it and start it again. You can quit Frontrow by entering Frontrow, and pressing Cmd-Opt-Esc.
-
Play with 100% volume This does not mean modify the movie to play with greater gain than the original movie file in the properties, but it does mean you shouldn’t change the volume level of the movie file. If it has been changed, set it to the top with the little volume slider. Most likely, you will not have to do anything with this step.
-
Check Channel Layout Note: Since Apple refuses to do the right thing and fix their bugs, A52Codec now attempts to detect this layout and adjust itself accordingly. This is yet another hack to work around Apple’s refusals to correct their errors. It may not work correctly in all circumstances. Due to bugs in Apple’s Quicktime components, (rdar:5799879 reported in March of 2008, not fixed), some methods of reading AC3 will have the wrong channel layout. Furthermore, due to issues related to how multi-channel audio is handled, the decoder is unaware of the order QuickTime expects (rdar:6921431). Make sure the channel layout is ordered: L, R, C, LFE, Ls, Rs. This can be verified by the “Show Movie Properties” within QuickTime Player. Select the audio track, and “Audio Settings”. It should look like this:
Note: I’ve been arguing with Apple about this one for almost 2 years now! For those within the company, see to it that rdar 5799879 and 6921431 get more attention than a single comment every 3-18 months! Either one would resolve this, but neither are getting response consistent with documentation. What’s worse is that Apple’s chosen layouts are even used anywhere! -
Check Receiver’s Settings As Dominik Pich pointed out, some receivers have an encoding setting. In his example, some Sony receivers need to be changed from
DEC PCM
toDEC AUTO
That’s it. Play you movies with AC3/DTS audio and enjoy your 5.1 system.
Edit: Added volume information which was missing. Edit: Added restarting the app which was missing.
Brand | Model | Works |
---|---|---|
Cambridge Soundworks | DTT-3500 | NO |
Creative | Inspire Digital 5500 | YES |
Creative | DDTS-100 | YES |
Denon | AVR-65 | NO |
Denon | AVR-786 | NO |
Denon | AVR-1706 | NO |
Denon | AVR-1803 | YES |
Denon | AVR-1910 | YES |
Harman Kardon | AVRs435 | YES |
JVC | RX-5060 | YES |
JVC | RX-5062 | YES |
KODA | AV-600 | YES |
Logitech | Z-5500 | YES |
Marantz | SR5200 | YES |
Marantz | SR5300 | YES |
Marantz | SR7200 | YES |
Onkyo | TX-DS575 | YES |
Onkyo | TX-SR507 | YES |
Onkyo | TX-SR605 | YES |
Onkyo | TX-SR606 | YES |
Onkyo | TX-SR674E | YES |
Onkyo | TX-SR707 | YES |
Onkyo | TX-SR876 | YES |
Panasonic | SA-HT40 | YES |
Panasonic | SA-XR70 | YES |
Pioneer | VSX-21-TXH | YES |
Pioneer | VSX-518 | YES |
Pioneer | VSX-1014TX | YES |
Pioneer | VSX-D906S | NO |
Pioneer | VSX-D2011 | YES |
Sherwood | RVD-6095RDS | YES |
Sony | DAV-HDX501W | NO |
Sony | STR-DE475 | YES |
Sony | STR-DE598 | YES |
Sony | STR-DE698 | YES |
Sony | STR-DE835 | YES |
Sony | STR-DE875 | YES |
Sony | STR-DG910 | YES |
Technics | SA-DA8 | YES |
Technics | SA-DX930 | YES |
Yamaha | DSP-A3090 | NO |
Yamaha | HTR-5250 | YES |
Yamaha | HTR-5950 | YES |
Yamaha | HTR-6063 | YES |
Yamaha | HTR-6160 | YES |
Yamaha | RX-V361 | YES |
Yamaha | RX-V365 | YES |
Yamaha | RX-V457 | YES |
Yamaha | RX-V461 | YES |
Yamaha | RX-V657 | YES |
Yamaha | RX-V667 | YES |
Yamaha | RX-V3900 | YES |
Yamaha | RX-V27000 | YES |
I’ve re-enabled comments on this post for the purposes of constructing a list of receivers which work and those that don’t. Please reply with the make/model of your receiver and whether it works. Comments disabled due to spammers.
Legacy Comments:
Push Eject - Feb 22, 2008
Thanks for the definitive post. Now my DVDs play in Front Row with AC3 passthrough just fine. M4Vs, however, do not. It seems to play the bitstream, but the receiver does not recognize it as valid ac3 and engage the decoder. Could the bitstream be corrupted on encoding or is this a failure of the m4v wrapper? Cheers!
Graham Booker - Feb 23, 2008
Push, Most likely that is related to the bug I filed with Apple in QT 7.3 (5594478), and 7.4 still failed to fix. Either way, it is a bug with Apple’s software. Demand they fix this; there is nothing I can do about it.
Push Eject - Feb 23, 2008
Thanks, Graham, will do.
Push Eject - Feb 27, 2008
I take it all back! Success! 5.1 via ac3 from an m4v Quicktime in Front Row! I basically went back through every setting and reset every option. I also uninstalled Flip4Mac and reinstalled Perian 1.1. The big thing seemed to be the AudioMidiSetup had not stuck (output was still at 44.1k) and the c0d3er.a52… passthrough setting was still at “0”. This in spite of my confirming the correct command line had been sent in Terminal (in fact I just went back in the Terminal history and hit “enter” to “fix” it). I reencoded a single chapter of a movie over and over in various wrappers and with various settings finally settling on .m4v h.264 with ac3 only. Many thanks, Graham. Mac Mini 10.5.2, Perian 1.1, Front Row 2.1.2 (232)
Graham Booker - Mar 3, 2010
Again, this is not a support forum. No further comments will be accepted here. Replies with Make/Model of receiver are examined and the information is added to the post, but such posts will not appear. Those attempting to abuse this system will be denied access.
Mario San Miguel - Mar 13, 2008
Thanks Graham!! And Push for giving the idea of uninstalling all my codecs. After manually taking out all my codecs and reinstalling perian the little blue dolby light is now on when playing through front row. And the best part is that I’m finding out that I have a lot of movies that it’s turning on for. Many thanks here too Graham.
Graham Booker - Mar 15, 2009
This is not a support forum. Any comments not pertaining to the make/model of a receiver and whether it works will be deleted.
Wim - Mar 23, 2008
Hello, What we would like to do is use a mac as a HD uncompressed 1920x1080 with 5.1 Surround player from Quicktime. The problem we had was that the receiver via Optical connection uses a stereo track (Toslink/SPDIF) and not a Multi-channel stream with 5.1 on the optical link… We have a full installed FCP Studio with compressor and soundtrack… What do we need to get it working?
Graham Booker - Mar 23, 2008
Wim, The SPDIF standard only allows either stereo PCM (uncompressed) data, or encoded digital audio (compressed). It does not allow 5.1 PCM (uncompressed) audio. For this, you need to get a computer audio device which has 6 discrete channels. In order to use the method I described above, you need to first compress the audio into AC3, and then play that back.
Wim - Mar 23, 2008
Hello, I’ve just embedded a uncompressed Quicktime with a Dolby AC3 5.1 Surround testfile and it is working on the system… You would need QT Pro to do this but this is a big step forward to a QT based Uncompressed HD playout… Maybe in the future the mac would be a 4K files based playout system with AC3 DOLBY 7.1 ;-)
Graham Booker - Mar 23, 2008
Wim, Yes, that would be nice. But for now, I have to seriously question Apple’s commitment to HD because of their lack of support for AC3 on their own (see http://www.cod3r.com/2008/03/wheres-real-ac3-passthrough-on-the-mac/). BTW, AC3 doesn’t do 7.1. You need Dolby Digital Plus, or Dolby TrueHD for that.
Wim - Mar 23, 2008
I’m talking with Apple from the post-production site of the story… I’ve also reported the bug… I would like to have this feature on every mac with optical out… Let’s hope they listen… Greetz, Wim
kra - Jul 1, 2010
Hi! So I guess everybody heard the news about the new macmini being hdmi compliant. Some steps are not necessary anymore. That’s actually what you should expect from an hdmi device, but well, it’s apple, so you want to double check. Here’s my setup, it seems to be working ok, even though I technically have not tested with 6 speakers (only 3) , nor with DTS: - AudioMidiSetup set to 96Khz/8ch/24bit. That’s the factory default actually. - Make sure the AC3/DTS attemptPassthrough are set to false. (defaults write blabla 0 or delete blabla). - Go to system preferences, perian and set audio output to “multi channel output” - You still need to update the channel layout. Apple apparently didn’t fix the bug. If you don’t, when playing AC3, even though it will play (it didn’t before), the channels will be all messed up (center goes to right, etc…). Good news is: it now also works for 6 channels discrete AAC. Yay! Good bye AC3, hello AAC. No need to change the channels layout with AAC. On my receiver (sony str-dg something, don’t have the exact reference, sorry), I get the blessed “blue light” indicating 5.1, identified as Linear PCM, so apparently QT is decoding everything and sending the decoded pcm to the receiver (which is consistent with the fact that channels get messed when playing ac3/m4v with standard layout). Overall, the situation improved: - Still has the ugly bug with ac3, - But aac 6 channels will work perfectly fine, - aac 6 channels will give you a decent workaround the ac3 bugs (only for new files, though) - Setup is less painful. Let me know if I said anything stupid (it is likely, I’ve just been testing around for the last hour), and I’d be glad to get any feedback from anybody with the fancy new macmini :)
Graham Booker - Jul 1, 2010
kra, You lose dynamic range. AC3 has greater dynamic range that what QT can handle.
Dominik Pich - Aug 7, 2009
For many recceivers, but especially some sony ones: set the receivers encoding! for sony for example it was: DEC PCM change it to: DEC AUTO voila :D
ionos - Aug 23, 2008
Oddest thing (All samples created with handbrake; please forgive me if I don’t get all the fancy abbreviations and terms right, I try my best): AVI Mpeg4 with AC3 - works in QT and VLC (i.e., DD sound) MKV H.264 with AC3 - works in QT and VLC So, it should be considered established that the receiver works, the cables work, stuff is installed ok, etc. M4V H.264 with AC3 - “Helicopter” in QT (i.e. the weirdo noise, input considered plain stereo by receiver), VLC seems to produce a valid stereo stream, but no surround sound. M4V H.264 with AC3 and AAC - same thing. Now, the funny part: In QT, open “Movie Properties”. Select Surround track, then “Audio Setting”. Swap “Right” and “Center”. Press play. Bang. Dolby Digital, say hello. Well, the receiver says the input was Dolby Digital, and I hear different things coming out of the various speakers. Now, does that mean that the right channel is being played on centre, and vice versa? Doesn’t sound like it, most talking still comes through the centre channel.
Graham Booker - Aug 23, 2008
ionos, On the audio settings, this is an issue with handbrake and it’s interaction with QuickTime. I suggested they use a version 2 atom in the m4v file 4 months ago (http://forum.handbrake.fr/viewtopic.php?f=4&t=4726&start=25#p33363) but was ignored. In addition, the default channel layout is inconsistent with Core Audio, which I reported to Apple 5 months ago (rdar 5799879) and was also ignored. If either of these two corrected they errors, this wouldn’t be an issue.
Jack - Oct 4, 2010
Thanks Graham great work!, Just to clarify: if “Multi-Channel Output” is selected in the Perian prefpane and passthrough is setup (following Graham’s instructions) then passthrough is on. But if anything else than “Multi-Channel Output” is selected in the Perian prefpane then passthrough is off. Allowing to easily switch if needed. Is this correct?
Graham Booker - Oct 5, 2010
Multi-Channel Output has nothing to do with passthrough. The method of turning it on and off are already described in this document.