CXO2's picture

[OpenAL] Get and Set the pan

Hello, I am trying to set the panning of the source.
And I was tried to explore AL.Source() but no clue..
I also cant find it under AL.GetSource() to get value of pan.. @___@

Someone know how to do this?
Thanks!


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

Assuming you have created a buffer and a source, panning the source is as simple as:

float x = -1;
float y = 0;
float z = 1;
AL.Source(source, ALSource3f.Position, x, y, z);
AL.GetSource(source, ALSource3f.Position, out x, out y, out z);

The following sample demonstrates how to create OpenAL buffers / sources.

CXO2's picture

Oh thank you fiddler @___@
dont worry, I have created the buffer and sources xD