|
> 1. [output stream] = [stream of floats] * (32767/maxfloat)
>
> 2. [output stream] = [stream of floats] * (32767.5/maxfloat)-0.5
Do #1. You don't get to decide about the offset, because
everyone else on the planet already recognizes zero as silence.
You know, it would be nice if the ADC would use -32768 to
indicate a clip! That way, we could get nice instant
feedback about exceeding levels. Actually, I have at least
one program that looks for this already. If the value -32768 is
encountered, it cries clip. This is not as accurate as if
the ADC had explicitly set it to indicate a clip in either
direction, but it is pretty close in practice.
Toby
|