Kodi Community Forum

Full Version: Getting the best 2 Channel sound out of Xbmc
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

I'm running a 2 channel system and I would like to get the best sound out of it, my media pc is running a recent nightly version (26th November 2011) on windows 7 64bit home premium.

My setup is this:
Flac music files (16 bit /44.1 khz)
xbmc set to Analog Wasapi STX
Asus Xonar STX drivers set to 44.1
Windows 7 sound set to 16 / 44.1
Analog cables from soundcard to pre-amp.

Am I getting bit-perfect playback this way? does xbmc do any re-sampling at all?

I remember when I setup xbmc on my old system I had to change the default player to DVDplayer in advanced settings to get bit-perfect, do I still need to do this?
Anyone?
Have you tried using an ASIO driver?
Assuming I've understood your setup correctly the sound is still passing through the D-A convertor in your PC, so the limiting factor is probably the audio circuitry in your PC. This may or may not be a problem depending on how expensive the rest of your HiFi is.

The only way to get the best out of your HiFi is to use a digital output i.e. optical or HDMI. If you use the optical output you can buy one of the many high end D-A convertors out there, but expect to pay a great deal of money! If you want a reasonably cheap but still pretty good way to try out optical audio have a look at http://www.lindy.co.uk/spdif-digital-to-...70408.html. I haven't tried this myself but it's been recommended to me by a few people.

HDMI provides digital sound, but I'm not sure what options are available for processing HDMI sound. Obviously you could use a home cinema amp, but unless you spend a fortune these aren't as good as high end audio amps so it seems a bit pointless. You might be able to find a HiFi DAC that handles HDMI input.

JR
In your case, the sound quality is only as good as the DAC in your Xonar soundcard. That's the place where the digital-->analog conversion happens. No resampling is guaranteed by your use of WASAPI. In that case the Windows settings do not matter.

Stereophile review

According to Stereophile you have a very good setup, once you configure it correctly. For XBMC, that means just selecting the WASAPI output option.
ashlar Wrote:In your case, the sound quality is only as good as the DAC in your Xonar soundcard. That's the place where the digital-->analog conversion happens. No resampling is guaranteed by your use of WASAPI. In that case the Windows settings do not matter.

Stereophile review

According to Stereophile you have a very good setup, once you configure it correctly. For XBMC, that means just selecting the WASAPI output option.

While that statement is factually correct and I agree whole heatedly in almost every way, unfortuently selecing WASAPI in XBMC currenty does not guarantee untouched audio as there is a very strange bug in the current nightlies that is causing windows to resample certain audio coming out of xbmc.


I've reported the bug in the forums and can reproduce it on all nightlies on a clean windows 7 XBMC build using south park as an example (episode available online) XBMC plays the audio but my AVR reports back that the stream is being resampled, I check, and it is. Windows is resampling the audio and then does not close the audio connection down correctly, then after the show ends, xbmc and windows leave open an audio connection of 5.1 in tht example (even though no audio is currently playing). The Only fix ive found so far is a XBMC reset.

I'm still trying to narrow it down as it it could be related to drivers or certain hardware (ion) but the upshot is that using WASAPI in xbmc nightlies at the Moment doesn't guarantee untouched audio Sad
Thanks for the replies.

The rest of the system is and Emotiva USP-1 Pre-amp & Emotiva XPA-2 Poweramp with B&W 684 speakers and a sub.

The sound is quite good with wasapi but I just wanted to know if there was any re-sampling done (to 48khz for example).

I've got some tracks that are 96khz/24bit but I understand that xbmc can only handle 16bit at the moment and will re-sample these to 16bit?
That's correct on the 16-bit truncation of 24-bit data. There is a new core component called AudioEngine under development which will allow 24-bit audio, but it wasn't ready for the next stable release coming year-end.

It also adds bitstreaming of the BluRay HD audio formats. If you search for AudioEngine you can find the main thread for it and info on some test builds using it.
Just checked out your soundcard, and it's got a very decent 24-bit Burr-Brown DAC. Aside from the Wasapi glitch noted above, you're well set up how you have things.

For CD-quality right now with XBMC you're pretty much set up as well as you can be. If you want to get the most out of higher-resolution sources like 24-bit Flacs, DVD-A or SACD you'll have to wait for the new AudioEngine mentioned above to start making the nightlies maybe next year.

For now I use Foobar 2K for high-def audio, although I do play around with XBMC builds including the as-is AudioEngine. Let me know if you need any help with either of those.
DDDamian Wrote:That's correct on the 16-bit truncation of 24-bit data. There is a new core component called AudioEngine under development which will allow 24-bit audio, but it wasn't ready for the next stable release coming year-end.

It also adds bitstreaming of the BluRay HD audio formats. If you search for AudioEngine you can find the main thread for it and info on some test builds using it.

Cheers. Do you know if it is possible to use foobar as an external player for audio?
automated Wrote:Cheers. Do you know if it is possible to use foobar as an external player for audio?

I assume so. It's certainly possible to configure external players for audio. For example, this configures XBMC to use mplayer for playing audio, and you'd only need to change the <filename> tag to use foobar.

Code:
<playercorefactory>
  <players>
    <player name="MPlayer" type="ExternalPlayer">
     <filename>C:\win32app\mplayer\mplayer.exe</filename>
     <args>"{1}"</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
    </player>
  </players>

  <rules action="prepend">
    <rule name="UseMPlayer" audio="true" player="MPlayer"/>
  </rules>
</playercorefactory>

JR
jhsrennie Wrote:I assume so. It's certainly possible to configure external players for audio. For example, this configures XBMC to use mplayer for playing audio, and you'd only need to change the <filename> tag to use foobar.

Code:
<playercorefactory>
  <players>
    <player name="MPlayer" type="ExternalPlayer">
     <filename>C:\win32app\mplayer\mplayer.exe</filename>
     <args>"{1}"</args>
     <hidexbmc>false</hidexbmc>
     <hideconsole>false</hideconsole>
     <warpcursor>none</warpcursor>
    </player>
  </players>

  <rules action="prepend">
    <rule name="UseMPlayer" audio="true" player="MPlayer"/>
  </rules>
</playercorefactory>

JR

Thanks a heap for that, I'll give it a go.
I haven't tried launching Foobar from XBMC but there's no reason why you couldn't.

You may try add the /nogui switch for Foobar to make it is seamless as possible. Change the above code to <args>"{1}" /nogui</args> and of course change mplayer.exe to foobar2000.exe....
Read this thread too, although I think /nogui might be better than /hide
http://forum.xbmc.org/showthread.php?tid=56253