]> git.alsa-project.org Git - alsa-plugins.git/commit
aaf: Tx multiple AVTPDUs per media clock tick
authorAndre Guedes <andre.guedes@intel.com>
Sat, 8 Dec 2018 01:55:49 +0000 (17:55 -0800)
committerTakashi Iwai <tiwai@suse.de>
Mon, 10 Dec 2018 08:42:27 +0000 (09:42 +0100)
commit5981b26afb64c562673436e2d199108bab109946
treeb76594351b402684d89e0259b8e93a2a81ca4ab2
parentce4e71d2bd181440dabe11ad3d9feda1d24fe758
aaf: Tx multiple AVTPDUs per media clock tick

In order to implement the transmission offload mechanism, we need to
change the way the plugin behaves so, instead of sending only one
AVTPDU, it sends several AVTPDUs at every media clock tick.

To achieve that, this patch changes the plugin so it consumes the audio
buffer in chunks of period size instead of in frames_per_pdu. The number
of AVTPDUs sent at every media clock tick is calculated by dividing the
period size by the number of frames per AVTPDU. To ensure that number is
not fractional, the plugin requires that the period size is multiple of
the plugin configuration 'frames_per_pdu'.

For the sake of consistency, the capture mode is also changed so the
plugin presents audio frames to the alsa-lib layer in chunks of period
size as well.

Signed-off-by: Andre Guedes <andre.guedes@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
aaf/pcm_aaf.c
doc/aaf.txt