Re: [linux-audio-user] Outputting same sound source to multiple cards simultaneously

From: Sampo Savolainen <v2@email-addr-hidden>
Date: Wed Jan 10 2007 - 12:43:31 EET

Quoting reuben firmin <reuben.firmin@email-addr-hidden>:

> With adequate buffering I think this shouldn't be a problem in my use
> case
> -- the speakers connected to the wireless device will be in a different
> room. You're not saying that a soundcard will get so far behind that the
> buffers will fill up, are you? Both soundcards are designed to output in
> ~"real time" after all.

Buffering doesn't fix the problem at all. It will maybe postpone it, but
nothing more.

Being "out of sync" translates to the fact the soundcards will consume
samples at different speeds. While the other one will consume 44101 samples
per second, the other one might consume 44030 samples per second.

Because of this, the sound emitting from the soundcards will drift apart.
Also, the pitch of the sound will differ.

Example: Just after 10 seconds, the 1st card in my example will be emitting
sample 441010 (44101 * 10), and the other card will be emitting sample
440300 (44030 * 10). This means that if the original audio has been recorded
at exactly 44100, the cards are already 0.016 seconds apart from eachother!
(44030 is an example of a really crappy clock chip on a card, but it's not
unheard of)

Let me re-iterate: Without syncing the soundcards, this /will/ happen. This
is not a legend or some far-fetched possibility that people speak of but
which really never affects real life.

Just imagine two wall-clocks. Can you really expect them to keep the exact
same time over years of continuous running without anyone re-setting them?

  Sampo
Received on Wed Jan 10 16:15:01 2007

This archive was generated by hypermail 2.1.8 : Wed Jan 10 2007 - 16:15:01 EET