Re: [AGL6.x][4a-softmixer]Question about purpose of using snd-aloop in module softmixer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dear Mr Luo,

The 4a softmixer is a sound server. It is a more secured, more CPU-friendly server than PulseAudio.

It is mandatory to have a sound server to share a sound card between
several applications, that may write to the sound card at different
sound rates and formats.

It is the responsibility of the 4a-softmixer to instantiate the dmix
alsa plugin, based on the 4A config files.


snd-aloop, which has recently been replaced by a more flexible implementation (called avirt), proxifies the access from playback application to sound cards.

The 4a-softmixer reads from snd-aloop (or avirt) captures, and
will perform the rate conversion, soft volume control for hardware that does not implement it, routing to configured audio channels,
and mixing at the end.

A security label (SMACK) can be put on the snd-aloop PCM playback devices, and since each these devices matches an audio role, that applications have to claim to the 4A high level API, this makes a gatekeeper for audio apps.

I agree that snd-aloop introduces one more buffer copy;
but the measured performances and CPU load on the tested
boards do not have revealed any unacceptable levels, up to now.
The CPU load (which could be even better with some unimplemented optimizations today) is typically less than 5% on the Renesas RCAR board, and similar numbers have been seen on Intel Atom boards.

Finally, some words about avirt.
Introduced recently on the master branch of AGL, it provides
to 4A high level a common interface for both softmixing,
and DSP-accelerated mixing. I also sets user-readable
names to the dynamically-configured playback devices, that
match the 4A audio roles (aka streams).

Hope this helps !

Best regards,
Thierry Bultel

On 04/01/2019 03:14 AM, luop wrote:
Hello,

    My name is Frank Luo, and I am an engineer of Neusoft.

     I just started studying the AGL audio system.

    After Reading the code of softmixer, I  realized that this module based on snd_aloop driver.  However,  I have a questions about this.

     What's the purpose of using this aloop as a sound card ?

        Audio data is passthrough the loop sound card(card 0), than written into the real sound card(card 1) by softmixer. The alsa plugins, including dmix plugin, are based on the real sound card.

        Audio data can be directly written into the real card(with the dmix plugin). So, I am wondering if  you could send me the intent of appending  this snd_aloop driver.

   Thank you, and I look forward to hearing from you.

Best Regards

------------------------------------------------------------------
Frank Luo(罗鹏)

Neusoft Automotive Solution Business Unit

Neusoft Corporation

901 Huangpu Road High-Tech Zone Dalian 116085, PRC

Tel: (86 411) 8446 6663

Fax: ((86 411) 8446 6742

Mobile:15840620310

Email:_luo.p__@neusoft.com_ <mailto:xxxxxxxxxx@xxxxxxxxxxx>

_www.neusoft.com <http://www.neusoft.com/>
_


---------------------------------------------------------------------------------------------------
Confidentiality Notice: The information contained in this e-mail and any accompanying attachment(s) is intended only for the use of the intended recipient and may be confidential and/or privileged of Neusoft Corporation, its subsidiaries and/or its affiliates. If any reader of this communication is not the intended recipient, unauthorized use, forwarding, printing, storing, disclosure or copying is strictly prohibited, and may be unlawful.If you have received this communication in error,please immediately notify the sender by return e-mail, and delete the original message and all copies from
your system. Thank you.
---------------------------------------------------------------------------------------------------



_______________________________________________
automotive-discussions mailing list
automotive-discussions@xxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/automotive-discussions

_______________________________________________
automotive-discussions mailing list
automotive-discussions@xxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/automotive-discussions




[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux