Topic: Linux: different audio output

I use Linux and have "ALSA" sound device and "HCA intel PCH ALC269". The default was ALSA and I had a delay between keypress and its sound (about 1/10...1/6 sec). I tried to fix this and had no result, but then I just changed device to HCA and (1) its sounds, (2) no delay.

So, why is difference in delay? And why I have two audio device output, although I have the single physical audio device on my laptop. This questions is just for my interesting, no real problem exists now.

Combine velocity curves: http://output.jsbin.com/cukeme/9

Re: Linux: different audio output

Which version do you use? On my system with Pianoteq 5 it looks a bit differently. Under Pianoteq Options I have two 'Audio device type': ALSA or JACK (I'm using ALSA).

Then I have 13 (!) 'Output's listed. Several Surround outputs, HDMI and so on. One is named 'Default ALSA Output', but I have chosen explicitly 'HDA Intel PCH, ALC283 Analog; Direct hardware device without any conversions'.

Maybe "... without any conversions" is the key.

Re: Linux: different audio output

Pulse Audio and JACK (if you have it installed/running) are audio daemons (also called audio servers) ... that means they launch and sit there waiting for audio requests to process.

By comparison, if you choose a specific hardware device, ALSA sends the audio directly to the hardware bypassing the audio daemons.  Hence you can see why you have better latency -- there is no extra step (and extra CPU processing) to get in the way.

So why would you ever choose an audio daemon?  Well the problem is when you output to a direct hardware device, that hardware device is locked.  Nothing else on the system can send audio out.   No big deal if you run Pianoteq in exclusion to any other program but if you do need extra audio processing software (say you need FluidSynth to do non-Piano instruments), then you have to pipe everything through an audio daemon.  In this scenario, you need a seriously beefy computer to get any decent kind of latency.

Re: Linux: different audio output

Mossy wrote:

By comparison, if you choose a specific hardware device, ALSA sends the audio directly to the hardware bypassing the audio daemons.  Hence you can see why you have better latency -- there is no extra step (and extra CPU processing) to get in the way.

You should reread my question. With ALSA I have a delay, with "HCA intel PCH ALC269" no delay. I have no audio servers (jack, pulse) on my machine. I think gropovy is right: the second device is direct to hardware, but ALSA is not. This is interesting why ALSA have too big latency?

Last edited by Ross (24-08-2014 10:43)
Combine velocity curves: http://output.jsbin.com/cukeme/9

Re: Linux: different audio output

Look at the dialog boxes.  Here's what it shows on mine:

Audio Output Device:
  [ ALSA ]

Output:
  [ Default ALSA Output (Pulse Audio) ]
  [ Pulse Audio ]
  [ HCA Intel .... ]
  [ HCA Intel .... ]
  [ HCA Intel .... ]
  [ HCA Intel .... ]
  [ HCA Intel .... ]

You must choose ALSA in option 1 before you can choose a direct hardware device.  Note that there is no such thing as just "ALSA" in the 2nd dropdown.  Yes, there is a "Default ALSA Output" option but you can clearly see "(Pulse Audio)" in parenthesis which means this option is no different from choosing "Pulse Audio" directly.

Last edited by Mossy (25-08-2014 02:56)