0
0

I’m new to FMODEx, but have been able to program some simple sounds without problem.

I know that FMODEx’s volume setting varies from 0 to 1.0, but does anyone know what dB range that equates to?

In DirectSound, each unit of volume setting is 1/100 dB so its range is from -100 to 0 dB.

I’ve searched the docs and previous forum messages and can’t find the answer.

TIA.

Lee

  • You must to post comments
0
0

Search DB in the help and you will find this tidbit in the spectrum doc

[quote:3ioptuhs]
spectrumarray

Address of a variable that receives the spectrum data. This is an array of floating point values. Data will range is 0.0 to 1.0. Decibels = 10.0f * (float)log10(val) * 2.0f; See remarks for what the data represents.

[/quote:3ioptuhs]

I don’t know if the value in the volume is setup the same way but some deductive reasoning and some testing may help you figure it out.

1.0f give -0DB attenuation

.00001f give about -100DB

0.5f give -6DB… and .5f in FMOD is half volume, since sound intensity drops by half every -6 db it makes sense.

  • You must to post comments
0
0

[quote="icuurd12b42":2nvfg55g]Search DB in the help and you will find this tidbit in the spectrum doc

[quote:2nvfg55g]
spectrumarray

Address of a variable that receives the spectrum data. This is an array of floating point values. Data will range is 0.0 to 1.0. Decibels = 10.0f * (float)log10(val) * 2.0f; See remarks for what the data represents.

[/quote:2nvfg55g]

I don’t know if the value in the volume is setup the same way but some deductive reasoning and some testing may help you figure it out.

1.0f give -0DB attenuation

.00001f give about -100DB

0.5f give -6DB… and .5f in FMOD is half volume, since sound intensity drops by half every -6 db it makes sense.[/quote:2nvfg55g]

Thank you for the info.

I think you are correct. The spectrum array appears to hold the volume setting which is converted to dB by the 20*log10(setting) formula.

I’ve always gotten confused on how much less dB results in half apparent loudness to the ear, etc. I think the "book" answer is that -10 dB is half loudness, not -6 dB. But I could be wrong. ๐Ÿ˜‰

The reason though this important is that I’m programming a crossfader and it’s essential that the dB curve of each channel are properly initialized.

  • You must to post comments
0
0

Yeah, I’m not sure either. I have taken electronics (which I failed 22 years ago) before programming… I just remember the 6db anecdote

If I remember, there is a difference between human perception and "actual power". Because to the human ear the value changes according to frequency range. 6dB is an average.

http://en.wikipedia.org/wiki/Decibe

BTW, I get 0 to -100 db, only if you max (v,.00001)… because volume 0 means infinite attenuation…

0 to -120 db if set it to .000001 if 0…

  • You must to post comments
0
0

[quote="icuurd12b42":19602kqe]Yeah, I’m not sure either. I have taken electronics (which I failed 22 years ago) before programming… I just remember the 6db anecdote

If I remember, there is a difference between human perception and "actual power". Because to the human ear the value changes according to frequency range. 6dB is an average.

http://en.wikipedia.org/wiki/Decibe

BTW, I get 0 to -100 db, only if you max (v,.00001)… because volume 0 means infinite attenuation…

0 to -120 db if set it to .000001 if 0…[/quote:19602kqe]

Yes, there is a difference. Supposedly 10 dB difference makes the human ear hear half/double the loudness.

6 dB is the difference for half/double the sound pressure.

And 3 dB is the difference for half/double the power.

Here’s a great website that discusses this and provides some online calculators. Much of it is in German, but the important pages are in English.

http://www.sengpielaudio.com/calculator-levelchange.htm

It also has a great discussion about the dB level when combining two or more sounds as a crossfader does.

It can all be rather confusing.

I appreciate your help. Programming a crossfader is actually a little more difficult in FMODEx over DirectSound. Assuming you have a table of the desired fader curve which is typically given in dB, then it is a simple matter to convert that to DirectSound volume level as there is a linear relationship between level and dB.

In FMODEx, you have convert the fader curve in dB to volume level using the 10^(dB/20) formula.

Lee

  • You must to post comments
0
0

I know from cross-fades in an editing environment that sometimes you want 3dB centre point, and some times a 6dB centre point to achieve even "loudness" through the cross-fade, as heard by the ear.

They are both valid for different source materials. Be prepared to use either.

  • You must to post comments
0
0

Yeah, decibels can be confusing…

[quote="Lee200":1ow84i4t]
I’ve always gotten confused on how much less dB results in half apparent loudness to the ear, etc. I think the "book" answer is that -10 dB is half loudness, not -6 dB. But I could be wrong. ๐Ÿ˜‰
[/quote:1ow84i4t]

[quote="icuurd12b42":1ow84i4t]If I remember, there is a difference between human perception and "actual power". Because to the human ear the value changes according to frequency range. 6dB is an average.
[/quote:1ow84i4t]

+/-1 Bel (+/-10 decibels) is by definition a 10x increase/decrease in electrical power or wave intensity … which in turn are the square of voltage and wave pressure, respectively. This is where the 10^(dB/20) formula comes from:
[list:1ow84i4t]
[i:1ow84i4t]Where P is the RATIO of two powers, and V is the RATIO of two voltages:[/i:1ow84i4t]
Bel = log(P)
dB = 10 log(P)
dB = 10 log(V^2)
dB = 20 log(V)
V = 10^(dB/20)
[/list:u:1ow84i4t]

-6 dB isn’t an average, it comes directly from calculating "half voltage" by that formula: 20 log(0.5) = -6.0206 which is close enough for casual use. (Why voltage? Because PCM wave data comes from sampling voltage levels. And "half" maps easily to FMOD values because FMOD uses multiplication to apply volume adjustments, since it’s cpu cheap.)

-6 dB also happens to correspond to distance doubling, since that results in half wave pressure according to the physics of wave propagation.

The notion of -10 dB being half "loudness" comes from experimental research in human perception of frequencies near 1000 Hz. Apparently we don’t hear "half the pressure" as being "half as loud." It’s a convenient coincidence that those results are so close to 10, as far as I can tell. Yet most music and game technology I’ve encountered use the physics measurements (6 dB) rather than the acoustic ones (10 dBA) for demarcation of reference points.

For full details, the websites others have cited in this thread are good references. Plus, I like this one: http://www.phys.unsw.edu.au/jw/dB.html

  • You must to post comments
0
0

Neet. Now I remember why I failed electronics in college.

  • You must to post comments
0
0

[quote="mattconnolly":1mtlr0a5]I know from cross-fades in an editing environment that sometimes you want 3dB centre point, and some times a 6dB centre point to achieve even "loudness" through the cross-fade, as heard by the ear.

They are both valid for different source materials. Be prepared to use either.[/quote:1mtlr0a5]

Absolutely. ๐Ÿ˜€

My understanding is that "coherent" sounds need a -6 dB crossover as the two sounds combine for a +6 dB increase.

"Incoherent" sounds need a -3 dB crossover as they combine for a +3 dB increase.

I’m a little fuzzy on the difference between coherernt and incoherent sounds other than two identical sounds are definitely coherent while two toally different sounds are incoherent. Apparently, it has something to do with their phase relationship.

Lee

  • You must to post comments
0
0

[quote="sgugler":1yyhnas9]
Yeah, decibels can be confusing…
[/quote:1yyhnas9]

Thanks squgler for the info. This is all good stuff.

I too would have failed electronics, but I was just smart enough NOT to major in electrical engineering. ๐Ÿ˜‰

Lee

  • You must to post comments
0
0

I learned something there too thanks sean :)

  • You must to post comments
Showing 10 results
Your Answer

Please first to submit.