
Introduction
How a Sample Rate Error Occurs.
The Effects of a Sample Rate Error.
Limitations.
How Ratefix works (This doc)
Ratefix will first analyze an audio file looking for patterns of repeated samples. Certain patterns are indicative of particular combinations of source and destination sample rates. Ratefix will make a guess as to what the real source sample rate was (or if you know it you can overwrite the suggestion with the correct value).
To correct a file that has Sampling Rate Glitches, it is necessary to:
1. Remove the duplicated samples
2. Correct the Sample Rate in the file header
This is a little tricky because not all duplicate samples are invalid. For example in a period of absolute silence there would be many samples in a row with a zero value. In practice even what appears as silence will have some small noise present, however it is quite possible to have very many legitimately repeated samples.
If the sample rates are such that for example, glitches occur on average every 12.3 samples, the Glitch Corrector must only remove repeated samples that occur after 12 samples, and every 30% of the time after 13 samples.
Knowing where we are in a sequence of samples is not obvious. Ratefix uses various algorithms to lock on to the repeating sample sequence (ignoring other legitimately repeating samples). It is not exact however (particularly in long passages of silence). When creating an output file Ratefix will calculate how many samples it expected to write and display how many it did write and the difference.
If the difference is small (less than 0.01%) then you may be seeing anomalies due to inexactness in the sample rate clocks of the sending and receiving devices.
A device that claims to be running at 48,000 samples per second will be a fraction of a percent out. It is therefore possible for Ratefix to work absolutely perfectly and still report a small difference between the number of samples calculated and written.
When creating a corrected file, Ratefix will write the correct source sample rate into the file header.