>Пятница,  8 января 2016, 10:14 +01:00 от Clemens Ladisch 
><cladi...@googlemail.com>:
>
>Sergei Steshenko wrote:
>>     Понедельник, 4 января 2016, 18:45 +01:00 от Clemens Ladisch < 
>> cladi...@googlemail.com >:
>>
>>     Sergei Steshenko wrote:
>>     > I have developed a piece of code (as LADSPA plugin) which among other 
>> things multiplexes one of two input streams into output stream.
>>     >
>>     > Though switching worked, latency was several seconds long instead 
>> fraction of a second.
>>     >
>>     > Because of the latency I suspected a problem with my code, but after 
>> creating a special test audio files I've established that the multiplexing 
>> happens fast - within my LADSPA host buffer length, as expected. And the 
>> buffer length was 1024 samples @44100KHz.
>>
>>     What is the buffer length of the device?
>>     (see /proc/asound/card*/pcm0p/sub0/hw_params)
>>
>> "buffer_size: 262144", and 262144/48000 is about 5.46 seconds - feels about 
>> right.
>
>The audio device is configured by whatever program actually writes to it,
>probably your host.  What is it?  How is it configured?
>
>
>Regards,
>Clemens

"The audio device is configured by whatever program actually writes to it" - 
the program is 'ecasound'. But the point is the buffer length is different for 
USB and non-USB cards.

For example, at the moment I am using "M-Audio Revolution 7.1", and for it I 
see:

"
sergei@amdam2:~/tmp> cat /proc/asound/card1/id
Revolution71
sergei@amdam2:~/tmp> cat /proc/asound/card1/pcm0p/sub0/hw_params
access: MMAP_INTERLEAVED
format: S32_LE
subformat: STD
channels: 2
rate: 44100 (44100/1)
period_size: 1024
buffer_size: 32768
".

Again, it's the same 'ecasound' with my audio stuff as LADSPA plugin for it. 
I.e. the code I wrote has no access to audio device.

For that matter, for on board "Nvidia", with a Youtube video playing through 
Firefox:

"at /proc/asound/card0/pcm0p/sub0/hw_params
access: MMAP_INTERLEAVED
format: S16_LE
subformat: STD
channels: 2
rate: 44100 (44100/1)
period_size: 44096
buffer_size: 88192
".

Regards,
  Sergei.



------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Alsa-user mailing list
Alsa-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/alsa-user

Reply via email to