mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
Added rewind to API in place of appl_ptr(). Moved aserver to a better place
This commit is contained in:
parent
b38376b91f
commit
fe92855cbb
17 changed files with 98 additions and 72 deletions
|
|
@ -173,6 +173,15 @@ ssize_t snd_pcm_mmap_appl_ptr(snd_pcm_t *pcm, off_t offset)
|
|||
return appl_ptr;
|
||||
}
|
||||
|
||||
void snd_pcm_mmap_appl_backward(snd_pcm_t *pcm, size_t frames)
|
||||
{
|
||||
ssize_t appl_ptr = pcm->mmap_control->appl_ptr;
|
||||
appl_ptr -= frames;
|
||||
if (appl_ptr < 0)
|
||||
appl_ptr += pcm->setup.boundary;
|
||||
pcm->mmap_control->appl_ptr = appl_ptr;
|
||||
}
|
||||
|
||||
void snd_pcm_mmap_appl_forward(snd_pcm_t *pcm, size_t frames)
|
||||
{
|
||||
size_t appl_ptr = pcm->mmap_control->appl_ptr;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue