Re: ALSA: fix excessive background noise introduced by OSS emulation rate shrink

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



At Sat, 21 Feb 2009 08:05:04 -0600,
Steve Chen wrote:
> 
> 
> Incorrect variable was used to get the next sample which caused S2
> to be stuck with the same value resulting in loud background noise.
> 
> Signed-off-by: Steve Chen <schen at mvista.com>

Oh what a long-living bug.
Applied now.  Thanks!


Takashi

> 
> diff --git a/sound/core/oss/rate.c b/sound/core/oss/rate.c
> index a466443..2fa9299 100644
> --- a/sound/core/oss/rate.c
> +++ b/sound/core/oss/rate.c
> @@ -157,7 +157,7 @@ static void resample_shrink(struct snd_pcm_plugin *plugin,
>  		while (dst_frames1 > 0) {
>  			S1 = S2;
>  			if (src_frames1-- > 0) {
> -				S1 = *src;
> +				S2 = *src;
>  				src += src_step;
>  			}
>  			if (pos & ~R_MASK) {
> 
> 
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux