Sign in

username:

password:



Not a member?

Search compdsp



Search tips

comp.dsp by Keywords

Adaptive Filter | ADPCM | ADSP | ADSP-2181 | Aliasing | AMR | Anti-Aliasing | ARMA | Autocorrelation | AutoCovariance | Beamforming | Bessel | Blackfin | Butterworth | C6713 | CCS | Chebyshev | CIC Filter | Circular Convolution | Code Composer Studio | Comb Filter | Compression | Convolution | Cross Correlation | DCT | Decimation | Deconvolution | Demodulation | DM642 | DSP Boards | DSP/BIOS | DTMF | Echo Cancellation | Equalization | Equalizer | ETSI | EZLITE (Ez-kit Lite) | FFT | FFTW | FIR Filter | Fixed Point | FSK | G.711 | G.723 | G.729 | Gaussian Noise | Goertzel | GPIO | Hilbert Transform | IFFT | IIR Filter | Interpolation | Invariance | JTAG | Kalman | Laplace Transform | Levinson | LPC | McBSP | MIPS | Modulation | MPEG | Multirate | Notch Filter | Nyquist | OFDM | Oversampling | Pink Noise | Pitch | PLL | Polyphase | QAM | QDMA | Quantization | Quantizer | Radar | Random Noise | Reed Solomon | Remez | Resampling | RTDX | Sampling | Sharc | TI C6711 | Undersampling | Viterbi | Wavelets | White Noise | Wiener Filter | Windowing | XDS510PP | Z Transform

Sponsor

Industry's highest performing at the lowest power DSPs now as low as $5.00*
Start development today!
*volume pricing for 10ku

Discussion Groups

Free Online Books

See Also

Embedded SystemsFPGAElectronics

Discussion Groups | Comp.DSP | Dither audio signal to 24 bits

There are 40 messages in this thread.

You are currently looking at messages 0 to 10.


Dither audio signal to 24 bits - 2004-07-04 10:38:00

Many DAW's offer internal 32 bit floating point data transfer and 
processing.  The question is, since the processing is done at 32 bit 
(and 64 bit) floating point then shouldn't dither be applied at 24 
bits when exporting to a 24 bit int format?  Also, even if the source 
material is at 16 bit int, shouldn't dither be applied at the end, 
since 32 bit float processing will produce information beyond the 
resolution of 16 bits?

On the Cakewalk Forum, I believe this was answered in the affirmative:
<http://www.cakewalk.com/forum/tm.asp?m=119201>; It's a very long 
discussion, but if you wade through it you get these points:

1. 32 bit float gives an actual 25 bits of resolution/information.
2. If no processing has been done, no dither is necessary even though 
the signal has been converted to 32 bit float.
3. You should always dither your final output, whether 24 bit or 16 
bit unless no processing has been done.
4. If you are going to do further processing, export to 24 bit using a
non-noise shaped dither at 24 bits.
5. The distortion that occurs when you DON'T dither is not necessarily
audible.

It could be that point 5. is the overriding factor making the 
discussion irrelevant.  But as far as I can tell, to avoid the 
distortion that occurs when reducing bit depths you should dither your
final output after DSP regardless of whether your source is 16 bit or 
24 bit, and regardless of whether your destination is 24 bit or 16 
bit.

I'd appreciate comments on this, but I'd also appreciate anyone who 
replies examining that thread above first, since that's where all of 
this is hashed out.  I'm bringing this up here because I'd like to 
know where the discussion on the Cakewalk Forum went wrong.

Thanks.
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Ben Bradley - 2004-07-05 00:40:00



On Sun, 4 Jul 2004 14:38:09 +0000 (UTC), s...@waterford.org
wrote:

>Many DAW's offer internal 32 bit floating point data transfer and 
>processing.  The question is, since the processing is done at 32 bit 
>(and 64 bit) floating point then shouldn't dither be applied at 24 
>bits when exporting to a 24 bit int format?  Also, even if the source 
>material is at 16 bit int, shouldn't dither be applied at the end, 
>since 32 bit float processing will produce information beyond the 
>resolution of 16 bits?
>
>On the Cakewalk Forum, I believe this was answered in the affirmative:
><http://www.cakewalk.com/forum/tm.asp?m=119201>; It's a very long 
>discussion, but if you wade through it you get these points:
>
>1. 32 bit float gives an actual 25 bits of resolution/information.
>2. If no processing has been done, no dither is necessary even though 
>the signal has been converted to 32 bit float.
>3. You should always dither your final output, whether 24 bit or 16 
>bit unless no processing has been done.
>4. If you are going to do further processing, export to 24 bit using a
>non-noise shaped dither at 24 bits.
>5. The distortion that occurs when you DON'T dither is not necessarily
>audible.
>
>It could be that point 5. is the overriding factor making the 
>discussion irrelevant.  But as far as I can tell, to avoid the 
>distortion that occurs when reducing bit depths you should dither your
>final output after DSP regardless of whether your source is 16 bit or 
>24 bit, and regardless of whether your destination is 24 bit or 16 
>bit.

   That's the "correct" thing to do. It's a lot more important to
dither when the destination is 16 bits, because the distortion
products will be 48dB louder than when going from something higher to
24 bits. Someone in that link (I did glance over it...) said he could
hear a difference between dithered and non-dithered 32float-to-24bits,
and I don't know maybe he does, but perhaps the software is doing
something else that makes it not sound as good that adding the dither
helps with.

>I'd appreciate comments on this, but I'd also appreciate anyone who 
>replies examining that thread above first, since that's where all of 
>this is hashed out.  I'm bringing this up here because I'd like to 
>know where the discussion on the Cakewalk Forum went wrong.

   This sort of thing has been discussed ad nauseum on rec.audio.pro
over the years, by people who do this stuff a lot, you might want to
read some of the archives through http://groups.google.com and if
(when) you still have questions, post over there.

>Thanks.

______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Stephan M. Bernsee - 2004-07-05 08:54:00

Well, I've not read the discussion on the Cakewalk forum, but in a
nutshell, dithering trades off distortion for noise. Since noise is
always cumulative, this is not something you would choose to do
automatically but rather something you would decide to use in some
cases, and in some rather not.

The importance of dither decreases as the wordlength of the output
increases. If your intermediate resolution across the whole processing
chain is 32 or 64bit floating point you don't have to worry about
requantization distortion that occurs *within* that part of the signal
path during processing. And if all you do is a straight "software
playthrough" 16 bit int -> 32 bit fp -> 16 bit int you don't even have
to worry about requantization at all.

But as for the *output* wordlength: if your target resolution is 8 or
16 bit, dither can be important because the distortion products from
the requantization may be above your noise floor and therefore
apparent.

If your target resolution is > 16bit we're talking about distortion
that occurs below or at -100dB DFS, you usually have enough noise
sources in your signal chain already (the noise of the A/D
converter(s) and (pre)amp(s) during track recording for example, or
the noise floor contained in a 16bit source file) that will mask the
distortion products resulting from a requantization to 24bit int after
the 32bit fp chain, so there's no need to add additional dither noise.
This is especially true in a multitrack environment where the noise
from all tracks adds up quickly and all tracks are scaled and mixed at
different volumes.

I'd say, for the case of 24bit output wordlength you wouldn't need to
worry much about requantization distortion, because in practice, (1)
the reproduction equipment generally can't handle the dynamic range to
make it audible and (2) there is generally enough noise present at the
required level before the requantization occurs that does the job for
you.

There may be one exception where I could see an advantage in dithering
during requantization to 24bit: If you're working entirely in
software, without any recorded tracks from the analog world (ie. using
softsynths only) it might be of advantage if you use dithering in the
24bit case, too, because some of these synths generate their signals
algorithmically and therefore contribute only very little to the
overall noise floor.

Does that help?

--smb
(DSP guy @ Prosoniq)

PS: I agree that this topic has been discussed in the rec.audio.pro NG
and on some mailing lists ad nauseam, and be aware that there are
always some extravagant claims from people who hear all kinds of
things (mostly without ever subjecting themselves to a double-blind
test), so I'd rather not go into this deeper than necessary here.
Dither noise is nothing mythical, it's a tool. Like other tools,
sometimes it makes sense to use it to yield an advantage, sometimes it
doesn't do anything besides adding even more noise to an already noisy
signal.
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - 2004-07-05 21:31:00

On Mon, 5 Jul 2004 12:54:57 UTC, s...@dspdimension.com (Stephan M. 
Bernsee) wrote:
> PS: I agree that this topic has been discussed in the rec.audio.pro NG
> and on some mailing lists ad nauseam, and be aware that there are
> always some extravagant claims from people who hear all kinds of
> things (mostly without ever subjecting themselves to a double-blind
> test), so I'd rather not go into this deeper than necessary here.

That's exactly why I asked on this group.  There's a much higher 
signal to noise ratio here.

>Dither noise is nothing mythical, it's a tool. Like other tools,
>sometimes it makes sense to use it to yield an advantage, sometimes 
it
>doesn't do anything besides adding even more noise to an already 
noisy
>signal.

What about on the ADC stage?  If the noise floor of your mics, pres 
and environment is higher than the resolution of your converter 
(-96dBFS for a 16 bit converter, yes?), do you need to add any 
additional dither noise to the signal before conversion?  
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Jerry Avins - 2004-07-05 23:39:00

s...@waterford.org wrote:

> On Mon, 5 Jul 2004 12:54:57 UTC, s...@dspdimension.com (Stephan M. 
> Bernsee) wrote:
> 
>>PS: I agree that this topic has been discussed in the rec.audio.pro NG
>>and on some mailing lists ad nauseam, and be aware that there are
>>always some extravagant claims from people who hear all kinds of
>>things (mostly without ever subjecting themselves to a double-blind
>>test), so I'd rather not go into this deeper than necessary here.
> 
> 
> That's exactly why I asked on this group.  There's a much higher 
> signal to noise ratio here.
> 
> 
>>Dither noise is nothing mythical, it's a tool. Like other tools,
>>sometimes it makes sense to use it to yield an advantage, sometimes 
> 
> it
> 
>>doesn't do anything besides adding even more noise to an already 
> 
> noisy
> 
>>signal.
> 
> 
> What about on the ADC stage?  If the noise floor of your mics, pres 
> and environment is higher than the resolution of your converter 
> (-96dBFS for a 16 bit converter, yes?), do you need to add any 
> additional dither noise to the signal before conversion?  

You NEVER want to add noise to the analog signal unless you want to
cover something else up. Dither isn't noise for noise's sake, it's a way
to convert quantization noise to something less offensive. An analog
signal has no quantization noise. Why would you dither it?

Jerry
-- 
Engineering is the art of making what you want from things you can get.
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Ben Bradley - 2004-07-06 00:32:00

On Mon, 05 Jul 2004 23:39:38 -0400, Jerry Avins <j...@ieee.org> wrote:

>s...@waterford.org wrote:

>> What about on the ADC stage?  If the noise floor of your mics, pres 
>> and environment is higher than the resolution of your converter 
>> (-96dBFS for a 16 bit converter, yes?), do you need to add any 
>> additional dither noise to the signal before conversion?  

   Yes, the included noise will tend to "self-dither" the signal, but
without the added dither noise, the noise already there can sound
"grainy." So even in this case, adding the appropriate amount of
dither noise can help preserve the original signal.

>You NEVER want to add noise to the analog signal unless you want to
>cover something else up. Dither isn't noise for noise's sake, it's a way
>to convert quantization noise to something less offensive. An analog
>signal has no quantization noise. Why would you dither it?

   If you're going from a analog into a "less-than-ideal" (16 bits or
less) A/D, adding noise for dither can help. An A/D converter is a
"bit-reduction" device that goes from lots of bits (infinite if you
listen to some people argue it) down to 16 bits, or however many bits
it gives. Here are my "usual links," the first involving A/D's, the
second descriobes dither totally in the "digital domain" [pun on the
name of the firm]:

http://www.national.com/an/AN/AN-804.pdf

Click on articles, then dither:

http://digido.com


>Jerry

______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Andor - 2004-07-06 05:40:00

scorey_plonk wrote:
...
> 1. 32 bit float gives an actual 25 bits of resolution/information.

There seems to be quite some disagreement about this in your forum. I
was down that avenue as well (search the comp.dsp archive). A 32bit
float can represent all the numbers a 25bit two's complement integer
can (plus lot's more). For unsigned 25bit integer you need to sign the
integer first (by offseting), otherwise you loose information when you
convert to 32bit float.


> 2. If no processing has been done, no dither is necessary even though 
> the signal has been converted to 32 bit float.

As long as you don't requantize, you don't need dither. Example:

1) Conversion from 25bit two's complement -> 32bit floating-point ->
25bit two's complement can be done without requantisation.

2) Conversion from 32bit two's complement -> 32bit floating-point ->
32bit two's complement _cannot_ be done without requantisation.

> 3. You should always dither your final output, whether 24 bit or 16 
> bit unless no processing has been done.

You should dither when you requantize - for example, you must dither
when converting a 24bit recording to 16bits (even if no processing is
done).

> 4. If you are going to do further processing, export to 24 bit using a
> non-noise shaped dither at 24 bits.

24bits two's complement is fine for storing (transfering) digital
audio - 32bit floating-point is better. The quantisation in 32bit
float is much finer than 24 (or 25) bit two's complement. If you want
to, you can add dither when converting from 32bit float to 24bit two's
complement. Your dither noise will drown in the noise floor of the
analog audio chain, it won't make much difference.

> 5. The distortion that occurs when you DON'T dither is not necessarily
> audible.
> 
> It could be that point 5. is the overriding factor making the 
> discussion irrelevant.  But as far as I can tell, to avoid the 
> distortion that occurs when reducing bit depths you should dither your
> final output after DSP regardless of whether your source is 16 bit or 
> 24 bit, and regardless of whether your destination is 24 bit or 16 
> bit.
> 
> I'd appreciate comments on this, but I'd also appreciate anyone who 
> replies examining that thread above first, since that's where all of 
> this is hashed out.  I'm bringing this up here because I'd like to 
> know where the discussion on the Cakewalk Forum went wrong.

You can also search the comp.dsp archives - lot's of talk about dither
there as well.

Regards,
Andor
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Richard Dobson - 2004-07-06 06:24:00

The standard range for 32bit float audio is +- 1.0, which makes full use 
of the 24bit mantissa (which then gives an effective 25bits becasue of 
the hidden bit); hence the very close relationship between 24bit int and 
32bit float. SO I would say the quantization is about the same (I have 
even heard of tricks that convert float to 24bit int by direct 
manipulation of the mantissa, rather than using the "proper" 
conversion). You will find for example that SoundForge will refer to 
24bit processing, when in fact they are using 32bit floats. They say 
they do this deliberately to make it clear that the precision is more 
akin to 24bits than "real" 32.

I agree there is no point in dithering to 24bit (at least from a 32bit 
float). You would need helium-cooled circuitry to escape the internal 
brownian noise of the electronics, and helium-cooled ears too to hear 
all the way down to -144dB, assuming you don't run it loud enough to 
damage your ears! Most 24bit DACs are unlikely to be truly linear down 
there anyway (without helium cooling...).


Richard Dobson

Andor wrote:
...
> 
> 24bits two's complement is fine for storing (transfering) digital
> audio - 32bit floating-point is better. The quantisation in 32bit
> float is much finer than 24 (or 25) bit two's complement. If you want
> to, you can add dither when converting from 32bit float to 24bit two's
> complement. Your dither noise will drown in the noise floor of the
> analog audio chain, it won't make much difference.
> 
> 
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - Stephan M. Bernsee - 2004-07-06 06:44:00

s...@waterford.org wrote:
> What about on the ADC stage?  If the noise floor of your mics, pres 
> and environment is higher than the resolution of your converter 
> (-96dBFS for a 16 bit converter, yes?), do you need to add any 
> additional dither noise to the signal before conversion?

The dynamic range for a 16 bit signal is ~96 dB.

If you mix several digitized, noisy signals (either 16bit with an
inherently higher noise floor or recordings from a mic, tape or
anything else that has even more noise in it) you usually don't
require extra dither noise at the output if your destination
wordlength is 24 bit or higher.

On average, most sampled realworld signals in the audio/music biz use
at most 18-20 bits for the actual signal, so there's quite a bit of
noise present already. In your DAW, you're mixing all these signals at
different ratios inside a 32bit fp signal path, thereby spreading the
noise over all fractions of the lowest few of your 24 output bits.

This effectively "auto-dithers" the signal with a Gaussian PDF noise.
Even though the Gaussian PDF isn't an ideal one for that purpose,
adding even more noise with a triangular PDF doesn't change much in
that case, except that it degrades the SNR further.

--smb
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: Dither audio signal to 24 bits - 2004-07-06 11:02:00

In article <l...@4ax.com>, 
b...@mindspring.com says...

>    If you're going from a analog into a "less-than-ideal" (16 bits or
> less) A/D, adding noise for dither can help. An A/D converter is a
> "bit-reduction" device that goes from lots of bits (infinite if you
> listen to some people argue it) down to 16 bits, or however many bits
> it gives. Here are my "usual links," the first involving A/D's, the
> second descriobes dither totally in the "digital domain" [pun on the
> name of the firm]:
> 
> http://www.national.com/an/AN/AN-804.pdf

(I had always thought of analog as having "infinite bits." is that not a 
useful way of looking at it?)

The pdf article states that in an ADC if the signal is at an amplitude 
of more than 10 bits above the LSB, then dither gives you no advantage 
in the dither-noise vs. distortion tradeoff.

Is this true when dithering a digital signal when reducing bit-depth?  
It seems like it would be...
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

| 1 | 2 | 3 | 4 | next