[Project] Dual Audio Output support (Krypton/Jarvis/Isengard/Helix/Gotham/Frodo) - Printable Version
+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (/forumdisplay.php?fid=32)
+--- Forum: Kodi Application (/forumdisplay.php?fid=93)
+--- Thread: [Project] Dual Audio Output support (Krypton/Jarvis/Isengard/Helix/Gotham/Frodo) (/showthread.php?tid=192480)
[Project] Dual Audio Output support (Krypton/Jarvis/Isengard/Helix/Gotham/Frodo) - xhbl - 2014-04-17 07:51
[03/13/2017] Added support for Krypton 17.0 and LibreELEC 8.0.0
[02/24/2017] Added support for Jarvis 16.1 and OpenELEC 7.0.1 / LibreELEC 7.0.3
[10/20/2015] Added support for Isengard 15.2 and OpenELEC 6.0.3
[04/19/2015] Added support for Helix 14.2 and OpenELEC 5.0.8
[10/18/2014] Updated to OpenELEC 4.2.1
[08/24/2014] Updated to Gotham 13.2
[06/06/2014] Added support for Gotham 13.1 and OpenELEC 4.0.4
[05/10/2014] Added support for OpenELEC 3.2.4
[04/17/2014] Initial support for Frodo 12.3 with new AudioEngine
Hi, for those who need 2-Zone simultaneous audio output might still remember this thread I posted years ago:
Now I'm back to bring a new supporting feature for Frodo(and later) which is the first version to use the powerful AudioEngine audio subsystem. I created this new thread also because of the totally different AudioEngine which makes the old patch inapplicable and this is a newly developed feature that is adapted to the AudioEngine.
The initial development of this project was under the support of lallhands in this forum. Thanks to him for encouraging me to start this project.
Currently Krypton/Jarvis/Isengard/Helix/Gotham/Frodo are supported, Different code are developed for them respectively. Be aware to pull the proper branch if you do your own build.
A screenshot of setting in Krypton
A screenshot of setting in Jarvis - Gotham
The dual audio output support Kodi built-in video player (videoplayer/dvdplayer) and music player (paplayer) as well as the GUI sounds. I've tested with the Windows and OpenELEC build and seems to be working well. as I mentioned above, in Gotham and later version, AudioEngine has been refactored to ActiveAE, so for Frodo, I only focused on the SoftAE which would support Windows WASAPI/Directsound and Linux ALSA/OSS. Although I implemented code for PulseAE/CoreAudioAE, it's mainly for passing the compiling. for Gotham, since AudioEngine had been refactored to a unified ActiveAE, all platforms should work.
Quite a few core source files needed to be modified to make this feature work which is a bit hacky, it's not considered to be a 'clean and decent' solution, thus there is the necessity to create a project to keep updating with the Kodi main project. Projects were created on github.
Branches with name suffix '-DA' are the Dual Audio branches, e.g., Krypton-DA, openelec-8.0-DA, etc. You can simply clone these repositories and pull the proper branch to make your own build.
For those who want to have a instant try, I build windows(only Kodi.exe[XBMC.exe before Helix], you need to install the original and replace exe file with this, for versions after Frodo, addtional xml setting files need to be replaced) and OpenELEC Generic 64bit version for your convenience:
12.3-Frodo (Windows DirectX): XBMC-12.3-dx-DualAudio-r019.zip
13.2-Gotham (Windows DirectX): XBMC-13.2-dx-DualAudio-r019.zip
14.2-Helix (Windows DirectX): Kodi-14.2-dx-DualAudio-r017.zip
15.2-Isengard (Windows DirectX): Kodi-15.2-dx-DualAudio-r020.zip
16.1-Jarvis (Windows DirectX): Kodi-16.1-dx-DualAudio-r015.zip
17.0-Krypton (Windows DirectX): Kodi-17.0-dx-DualAudio-r015.zip
OpenELEC(builds by DarkAngel2401): OpenELEC-DualAudio-builds-by-DarkAngel2401
LibreELEC(builds by DarkAngel2401): LibreELEC-DualAudio-builds-by-DarkAngel2401
Any suggestions for the future of this project, you are welcome to PM or email me. Enjoy!
DONATE to this project
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - quartermain - 2014-04-18 11:22
It would be very interesting if you did decide to develop this for Gotham.
I have been looking for a dual-audio solution for some time. I need it so I can listen via the 5.1 speaker system while my wife who is hard of hearing can listen using cordless headphones.
I finally decided to use an Atlona AT-HD-M2C fed by a HDMI splitter. This solution isn't cheap and with the splitter means more boxes, more cables and more power supplies. Dual audio from XBMC would be a much neater solution.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - Andycots - 2014-04-19 08:53
Great stuff, been looking and following the old Eden post for a while now hoping for this to come to Frodo, well done on your hard work.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - quartermain - 2014-04-19 11:55
OK I tried the Windows version first. I set the first audio output to HDMI and 5.1, with the audio output device WASAPI. Second audio ouput to Analogue and 2.0, audio output device WASAPI - I had to scroll through these until I heard a sound in the headphones I had plugged in.
I played a 5.1 speaker setup test. The headphone output was perfect, all 6 channels audible and in the right place. However there was a problem with the 5.1 output - front and LFE were OK but I could hear the surround channels through the front right and left speakers as well as the rear right and left.
I will try the OE version later today.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - quartermain - 2014-04-19 13:08
OE fared better than Windows - I could get 5.1 to the speakers and a downmix to the headphones from lots of my test files, and all the channel placement was correct.
Unfortunately Frodo has problems that have been fixed in Gotham. If I bitstream the sound, Dolby TrueHD and DTS MA samples play at extremely low volumes (this may be an interaction between XBMC and my A/V receiver). If I send LPCM then most test files are OK but one I have which uses Dolby TrueHD has stuttering video and audio. And an irritation of OE 3.2 is that it doesn't work with my Logitech K400r cordless keyboard/trackpad. All these problems go away if I use a dev build of OE/Gotham.
I also noticed that the sound through the headphones was slightly ahead of that through the speakers. Watching actors lips suggest that the headphones are spot on and the speakers slightly behind, but it's so close that it wouldn't be noticeable in normal use unless you could hear both headphones and speakers at the same time.
So this is *almost* enough for me to forget about buying the Atlona box, but not quite. If the same patches were applied to Gotham it would be a different story - then I would definitely go for it.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - Juno - 2014-04-19 18:40
How to install this patch:
Didnt noticed already compiled vweriosn of OE.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - wsnipex - 2014-04-19 21:11
gotham on linux doesn't need an dual audio patch, you can do the same and more with the new pulse audio support.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - Juno - 2014-04-19 22:37
Thank You wsnipex but i cant.
I installed gotham based openelec and with my stereo analog amplifier connected via optical and tv connected via hdmi i cant have two audio in same time. As i want to listen to music i have to change settings everytime after i watched tv. And vice versa. Thats highly unconvenient.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - wsnipex - 2014-04-20 20:35
OE doesn't include pulse afaik. If dual audio on gotham is important to you, you might be better off with ubuntu or another normal linux dist.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - dhead - 2014-04-22 09:34
It's there, it just not enabled in the build process (I didn't tested its usability)
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - wsnipex - 2014-04-22 11:57
nice, so its all there, but must be enabled during build.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - botez - 2014-04-22 23:40
Awesome work, xhbl. I've been annoyed at the extra hardware and various hacks I've had to use to get this functionality, so it's exciting to see this (and in Openelec as well, which is what I use!). Great stuff.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - mrdally204 - 2014-04-23 13:28
Adding my thank you as well. This feature is one of those must haves that I have missed since the Frodo release. I have since upgraded to Gotham for testing purposes so I am unable to take advantage of your work at present. Hopefully a Gotham release is in the not too distant future. Welcome back to the community!
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - taxigps - 2014-04-24 12:04
welcome back xhbl.
RE: [PATCH] Return of the Dual Audio Output support (Frodo...) - marco.weinkauf - 2014-04-26 10:53
sounds very promising to finally implement the desired solution for my htpc.
I have a question for this patch.
Is it possible to have on audio1 TrueHD or DTS-MA HDMI passthrough and on audio2 analog stereo at the same time?