Discussion:
Some qustion about the distance and capture
chaoshikari
2012-04-26 15:45:18 UTC
Permalink
Im new to openal, and I met some problems while trying to use it.
1.Does the AL_SPEED_OF_SOUND affect the listener? Will it apply a delay
between listener and source while the distance is long?
2.Could the capture functions be used to capture what listener hears?
3.How does the gain works?I called the function
alDistanceModel(AL_NONE), but nothing happens. Then I tried to call
alListenerfv(AL_GAIN,AL_NONE), it gives out an error.
Thank you.:-)
Jason Daly
2012-04-26 16:03:22 UTC
Permalink
Post by chaoshikari
Im new to openal, and I met some problems while trying to use it.
1.Does the AL_SPEED_OF_SOUND affect the listener? Will it apply a delay
between listener and source while the distance is long?
The AL_SPEED_OF_SOUND parameter only affects the calculations for the
Doppler effect. The equations for the Doppler effect are in the OpenAL
specification.
Post by chaoshikari
2.Could the capture functions be used to capture what listener hears?
Not in unextended OpenAL. OpenAL-Soft version 1.14 has an extension to
accomplish this:

http://kcat.strangesoft.net/openal-extensions/SOFT_loopback.txt
Post by chaoshikari
3.How does the gain works?I called the function
alDistanceModel(AL_NONE), but nothing happens. Then I tried to call
alListenerfv(AL_GAIN,AL_NONE), it gives out an error.
What do you mean by how does the gain work, exactly? What are you trying
to do with it? In general the gain specifies how much to attenuate the
sound stream before rendering it. Floating point values between 0 and 1
are typical.

alListenerfv expects a pointer to an array of values, so I'm not
surprised that you got an error.

You might want to read the specification to get a better understanding
of how this all works:

http://connect.creativelabs.com/openal/Documentation/OpenAL%201.1%20Specification.pdf

--"J"

Continue reading on narkive:
Loading...