Re: [alsa-devel] compressed audio support (maruthi srinivas)
Hi,
I saw that compressed audio framework being used with Asoc (alsa soc). Can the framework be used with other than Asoc ? I mean with ALSA pci based cards.
Never worked on this so don't know.
I see the implementation in the following files. which one is to be used ? Does tinycompress in userspace can be used with either approaches ?
This will not be relevant after you see below answer.
http://lxr.free-electrons.com/source/sound/core/compress_offload.c http://lxr.free-electrons.com/source/sound/soc/soc-compress.c
Both are compress framework driver files. compress_offload.c file is the one which interacts with userspace by using ioctl's, registers the compressed device with alsa framework(/dev/compress* gets created because of that), calls the corresponding functions such as trigger, pointer update, copy and others when userspace pauses, plays and stops the playback or recording.
soc_compress.c file is the file which interacts with compress_offload.c file to create a 'dev' node for compress driver.Basically when you register your compress driver with compress framework,alsa core will come to know that your dai support compress operations and it will create the dev node by using soc_compress.c file.The functions in this file gets called by compress_offload.c functions and who inturn gets called by the userspace.
userspace->compress_offload.c->soc_compress.c->your_compress_driver.
On Mon, Dec 02, 2013 at 03:24:51PM -0800, anish singh wrote:
Both are compress framework driver files. compress_offload.c file is the one which interacts with userspace by using ioctl's, registers the compressed device with alsa framework(/dev/compress* gets created because of that), calls the corresponding functions such as trigger, pointer update, copy and others when userspace pauses, plays and stops the playback or recording.
soc_compress.c file is the file which interacts with compress_offload.c file to create a 'dev' node for compress driver.Basically when you register your compress driver with compress framework,alsa core will come to know that your dai support compress operations and it will create the dev node by using soc_compress.c file.The functions in this file gets called by compress_offload.c functions and who inturn gets called by the userspace.
userspace->compress_offload.c->soc_compress.c->your_compress_driver.
userspace->compress_offload.c->your_compress_driver.
this will work too, as i said you are not bound to asoc but to framework like PCM. We can have PCM alsa driver like PCI or something else or ASoC
-- ~Vinod
participants (2)
-
anish singh
-
Vinod Koul