From 7b29b8d545ec74ee1dda3ec8180666a4947df4a5 Mon Sep 17 00:00:00 2001 From: kent Date: Sat, 12 Mar 2005 03:55:45 +0000 Subject: [PATCH] Fix a problem that the resultant stream contains many garbage data at stereo->mono conversion. PR#29664 --- sys/dev/aurateconv.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/aurateconv.c b/sys/dev/aurateconv.c index a1deddc6ba9b..95d156b20ea9 100644 --- a/sys/dev/aurateconv.c +++ b/sys/dev/aurateconv.c @@ -1,4 +1,4 @@ -/* $NetBSD: aurateconv.c,v 1.11 2005/03/12 03:42:03 kent Exp $ */ +/* $NetBSD: aurateconv.c,v 1.12 2005/03/12 03:55:45 kent Exp $ */ /*- * Copyright (c) 2002 The NetBSD Foundation, Inc. @@ -37,7 +37,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: aurateconv.c,v 1.11 2005/03/12 03:42:03 kent Exp $"); +__KERNEL_RCSID(0, "$NetBSD: aurateconv.c,v 1.12 2005/03/12 03:55:45 kent Exp $"); #include #include @@ -301,7 +301,7 @@ aurateconv_fetch_to(stream_fetcher_t *self, audio_stream_t *dst, int max_used) do { \ if ((FROM)->channels == 2 && (TO)->channels == 1) { \ WRITE_S##BITS##EN(WP, ((V)[0] + (V)[1]) / 2); \ - WP = audio_stream_add_inp(STREAM, WP, (BITS) / NBBY * 2); \ + WP = audio_stream_add_inp(STREAM, WP, (BITS) / NBBY); \ } else if (from->channels <= to->channels) { \ int j; \ for (j = 0; j < (FROM)->channels; j++) { \