Forwarded mail from Alexander Patrakov:
"Alexander E. Patrakov" <[EMAIL PROTECTED]> writes:

> Please look at xine-lib-1.1.2/src/xine-engine/resample.c
>
> This file contains sound resampling functions. They have the property
> that the first sample of the output data is the same as the first input
> sample, and the last sample of the output data is the same as the last
> input sample. And they don't keep any state between resampling chunks,
> i.e., the first call resamples the first N samples, then the next call
> resamples the next N samples completely independently. The properties
> mentioned above guarantee incorrect behaviour at chunk boundaries.
>
> Namely, suppose that the original sample rate is 22.05 kHz, thus, the
> interval between samples is normally 45.351 us. Xine concerts the first
> 576 samples to 48 kHz, then it converts the next 576 samples. However,
> the input sample 575 (counting from zero, i.e., the last sample of the
> first chunk) maps _exactly_ to the output sample 1253, and the input
> sample 576 maps _exactly_ to the output sample 1254. The time distance
> between these signal values becomes 20.833 us instead of the correct
> 45.351 us. In other words, all data that should be inserted between
> these output samples are lost. This manifests itself as a click if the
> signal has a non-zero derivative at that point.
>
> The problem is aggravated by the fact that, in the default ALSA dmix
> setup, xine always resamples its output to 48 kHz (even though ALSA can
> do it better itself with "plug" and libsamplerate), thus, all narrowband
> internet radios suffer from clicks in xine.
>
> If you can't fix the xine resampler, please make sure it is not used in
> the default plug:dmix setup.

I checked with current cvs, but that file didn't change. Perhaps someone
on xine-devel can do something with this suggestion?

-- 
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to