From alsa-devel-owner@alsa.jcu.cz  Sat Jan 23 22:02:07 1999
Received: from post.mail.demon.net (finch-post-10.mail.demon.net [194.217.242.38])
	by marvin.jcu.cz (8.9.1a/8.9.1) with ESMTP id WAA29536
	for <alsa-devel@alsa.jcu.cz>; Sat, 23 Jan 1999 22:00:46 +0100
Received: from [158.152.21.220] (helo=muse)
	by post.mail.demon.net with smtp (Exim 2.10 #1)
	id 104AAY-0006zJ-00
	for alsa-devel@alsa.jcu.cz; Sat, 23 Jan 1999 21:00:38 +0000
Received: by muse with Microsoft Mail
	id <01BE4713.64D3B7A0@muse>; Sat, 23 Jan 1999 21:00:23 -0000
Message-ID: <01BE4713.64D3B7A0@muse>
From: "Richard W.E. Furse" <richard@muse.demon.co.uk>
To: "'alsa-devel@alsa.jcu.cz'" <alsa-devel@alsa.jcu.cz>,
        "'cdavid@umich.edu'" <cdavid@umich.edu>
Subject: RE: hi-res pcm sound support/IEEE floats
Date: Sat, 23 Jan 1999 20:59:42 -0000
Reply-To: alsa-devel@alsa.jcu.cz
Sender: alsa-devel-owner@alsa.jcu.cz
Precedence: list

I agree with your approach to the argument--what to do with the 'spare' 
eight bits. Yes, as far as the ear is concerned 24bits with 48dB of volume 
control (8bits on mantissa) will sound identical to 24bits with 1541dB of 
volume control (8bits on exponent) assuming the volume control is roughly 
in the right place. And for many applications this is all you'll ever want. 
In effect the difference is how far you can twiddle the volume knob without 
compromising your 24bits of detail. 48dB is significantly less than the 
range provided by a normal mixing desk. 1541dB is rather more...

Presumably the audio has come into the PC through all this expensive 
hardware so the computer can do something with it. If the computer is going 
to do anything complex with it (e.g. in Csound) it will go through multiple 
processing stages. Using integers, at each of these stages the user needs 
to ensure the output of the process is making full and correct use of the 
dynamic range available or distortion/noise or clipping will occur. It is 
not always enough to let a signal amplitude slip as it passes through 
multiple filters and then amplify it into the right range at the end of the 
signal path--if the signal hits the floor or ceiling of the 32bit channel, 
it is not recoverable. The user could perhaps scale the coefficients of 
each processing stage to produce as accurate a signal as would be achieved 
using floats--but by the time the user has tweaked every filter gain in the 
chain, changed his set-up slightly and gone through tweaking them all 
again, he/she has probably forgotten how the piece was supposed to go 
anyway! And if an error was made it will be difficult to work out exactly 
which step in the chain
induced the noise/harmonic distortion/clipping.

I'm being a bit argumentative here--48dB is a lot of slack and absolutely 
luxurious when compared to working with 16bit audio. For dedicated 
processing that just needs to be set up once and then left alone it would 
be fine once the programmer has recovered... But as a Csound user, with 
fairly simple instrument designs I find it quite usual to need to multiply 
or divide a signal by 10^8 or more to pull it into the correct range for 
output. If Csound used 32bit integers internally I'd be up against serious 
clipping or at best a noise floor at 27dB.

To summarise, using floats allows one to set the volume level of a signal 
chain where one wants (normally at the end) rather than having carefully to 
balance every step along the way to prevent signal damage that can be 
difficult to locate. To me this seems a very practical consideration.

Hmm. That was another rant--apologies--it's probably because I wrote an 
additive synthesis programming language (HISS) initially using a 32bit int 
synth engine. The logic was that it would provide performance that Csound 
didn't always deliver on a 486. Let's just say it wasn't a very pleasant 
experience and I've used floats ever since...

Cheers,

-- Richard

-----Original Message-----
From:	Chris David [SMTP:cdavid@umich.edu]
Sent:	Saturday, January 23, 1999 6:35 PM
To:	'alsa-devel@alsa.jcu.cz'
Subject:	RE: hi-res pcm sound support/IEEE floats



On Sat, 23 Jan 1999, Richard W.E. Furse wrote:

> Hmmm. Absolutely right of course--I've reread the docs to work out how
> on Earth I came to my earlier conclusions! Many apologies.
>
> However floats are still the way to go by the S/N arguments at least...
>
> -- Richard
>

I'm still not 100% convinced.  I see that floats have an advantage to be
able to represent a signal of a very low DB, and also at a high DB.  The
dynamic range is huge. But how useful is this really for real world
applications?  I mean if a real signal used even a 1/100 of the
dynamic range of a signal, the low end would be inaudible, and the high
end would blast your ears out. It seems to me a waste of bits.

So lets comapare IEEE 32 bit floating point with 32 bit ints for a second.
It seems to me, as far as dynamic range goes, a 32 bit int would be
equivalent to a float with a 24 bit mantissa with a 3 bit exponent.  ( 2 ^
3 = 8)  Do you not think that the 3 bit exponent would provide enough
dynamic range to accomplish the things you outlined in that first message?
I think it would.

If you do think that, then it follows that the 32 bit int can accomplish
those things, plus it has the advantage of an extra 8 bits resolution.

So I guess my point is... Does the 8 bit exponent really provide a
useful advantage?

-Chris







------
To unsubscribe from <alsa-devel@alsa.jcu.cz> mailing list send message
'unsubscribe' in the body of message to <alsa-devel-request@alsa.jcu.cz>.
