alsa: separate max_error and max_resync

Use a separate variable to hold the maximum amount of drift we allow
between driver and follower. Ensure this value is smaller than the max_error
and period size so that we have at most 1 period of drift.
This commit is contained in:
Wim Taymans 2023-04-10 16:28:55 +02:00
parent 30657abf28
commit 261fb64849
2 changed files with 8 additions and 4 deletions

View file

@ -213,6 +213,7 @@ struct state {
struct spa_dll dll;
double max_error;
double max_resync;
struct spa_latency_info latency[2];
struct spa_process_latency_info process_latency;