From: Zeno Endemann Date: Mon, 29 Jan 2024 14:02:44 +0000 (+0100) Subject: pcm: document interaction of drain silence and sw silence X-Git-Tag: v1.2.11~1 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=ffed4f342678c31bf0b9edfe184be5f3de41603a;p=alsa-lib.git pcm: document interaction of drain silence and sw silence I'm not sure this is the best way to describe the interaction, but I think this needs to be mentioned in some form at least. Closes: https://github.com/alsa-project/alsa-lib/pull/381 Signed-off-by: Zeno Endemann Signed-off-by: Jaroslav Kysela --- diff --git a/src/pcm/pcm.c b/src/pcm/pcm.c index bd819a00..ab3bbda7 100644 --- a/src/pcm/pcm.c +++ b/src/pcm/pcm.c @@ -6895,6 +6895,10 @@ int snd_pcm_sw_params_get_silence_threshold(const snd_pcm_sw_params_t *params, s * underrun is nearer than silence threshold (see * #snd_pcm_sw_params_set_silence_threshold) * + * When drain silence (see #snd_pcm_hw_params_get_drain_silence) is disabled, + * this will also apply for draining, i.e. silence is written also when the + * drain end is nearer than the silence threshold. + * * The special case is when silence size value is equal or greater than * boundary. The unused portion of the ring buffer (initial written samples * are untouched) is filled with silence at start. Later, only just processed