From 8d94accc495ae4d9032796f3c302f1e88078ba85 Mon Sep 17 00:00:00 2001 From: Jaroslav Kysela Date: Wed, 24 Nov 1999 18:17:20 +0000 Subject: [PATCH] Added rounding... --- src/pcm/pcm_plugin.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pcm/pcm_plugin.c b/src/pcm/pcm_plugin.c index a460e5ab..cea52dfe 100644 --- a/src/pcm/pcm_plugin.c +++ b/src/pcm/pcm_plugin.c @@ -296,7 +296,7 @@ static void swap_formats(int channel, int *src, int *dst) *dst = tmp; } -#define CONVERT_RATIO(dest, ratio) dest = (int)((double)dest * ratio) +#define CONVERT_RATIO(dest, ratio) dest = ((int)(((double)dest * ratio)+0.5)) int snd_pcm_plugin_params(snd_pcm_t *pcm, snd_pcm_channel_params_t *params) { -- 2.47.1