Christopher Howard
2012-10-13 02:25:40 UTC
Hi. Hopefully this is the correct place to ask really basic OpenAL/ALUT
programming questions. I'm using them through Haskell language bindings.
Of course, I don't expect you guys to support foreign language bindings,
but I'm hoping my problem stems from some stupid, obvious mistake or
oversight, rather than a module specific issue.
In short: My app plays sources without any trouble. Also, I can manually
set the gain of individual sources. However, I don't seem to be getting
any distance based attenuation at all. The volume of the source always
sounds the same regardless of the distance between source and listener.
I'm hoping I have made some common newbie configuration oversight or
mistake.
My system:
Gentoo Gnu/Linux amd64
openal-1.13 from strangesoft.net
freealut-1.1.0-r1
Stuff I do in my program:
- initialize ALUT
- load buffers from files with ALUT loader
- set distance model to exponential (I've tried a few others as well)
- create source for object and attach buffer to it
- set source relative to listener
- set reference distance of source to reasonable value (though I've
tried various other large and small values)
- connect source position of source to coordinates of object (this is
updated every step of the event loop) that moves around
- connect listener position to coordinates of a difference object
(updated every step) that moves around
- play source when appropriate
programming questions. I'm using them through Haskell language bindings.
Of course, I don't expect you guys to support foreign language bindings,
but I'm hoping my problem stems from some stupid, obvious mistake or
oversight, rather than a module specific issue.
In short: My app plays sources without any trouble. Also, I can manually
set the gain of individual sources. However, I don't seem to be getting
any distance based attenuation at all. The volume of the source always
sounds the same regardless of the distance between source and listener.
I'm hoping I have made some common newbie configuration oversight or
mistake.
My system:
Gentoo Gnu/Linux amd64
openal-1.13 from strangesoft.net
freealut-1.1.0-r1
Stuff I do in my program:
- initialize ALUT
- load buffers from files with ALUT loader
- set distance model to exponential (I've tried a few others as well)
- create source for object and attach buffer to it
- set source relative to listener
- set reference distance of source to reasonable value (though I've
tried various other large and small values)
- connect source position of source to coordinates of object (this is
updated every step of the event loop) that moves around
- connect listener position to coordinates of a difference object
(updated every step) that moves around
- play source when appropriate
--
frigidcode.com
indicium.us
frigidcode.com
indicium.us