Search found 20 matches

by Mckl
Mon Apr 20, 2020 4:22 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

Oh so I can just during initialization or in update just put something like:
AL_MAX_Distance = 20;
AL_Reference_DIStance = 5 and this would adjust sound for me.
And what about ROLLOFF Factor?
by Mckl
Sun Apr 19, 2020 9:57 pm
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

I am wondering is there a way manually attune the distance model. When bot car in close vicinity accelerate it seems too silent or weak.
by Mckl
Thu Apr 16, 2020 9:41 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

There is no multithreading. I just made frame counter and put it into update function so after around 100 frames when all vehicles are there counter stops and then all sources are generated exactly once using some bool variable. and then Update function starts working normally. like I have now all i...
by Mckl
Thu Apr 16, 2020 6:56 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

It turns out that vehicle list on moment of initialization of sound system is empty. Vehicles generated after Sound system is initialized. So I ve made it to wait for few seconds. Now it seems it's all there. Thank you could not have figured with out your help. Now I just need to do attunement. As I...
by Mckl
Wed Apr 15, 2020 5:05 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

It's not that It's somehow do not recognize it as source no matter what I do. My last attempt : in initialization function auto vehicles = getEngine()->getSubSystem<EngineStore>()->getRoot().getComponentsOfType<Component::Vehicle>(); for (auto& vehicle : vehicles) { if (vehicle->type == Componen...
by Mckl
Wed Apr 15, 2020 1:38 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

I am running into an issue in our vehicle class I ve put ALuint aiSource. In initialization function I ve put: for (auto vehicle : vehicles) { if (vehicle->type == Component::Vehicle::Type::Player) { continue; } ALuint source; alCall(alGenSources, 1, &source); alCall(alSourcef, source, AL_PITCH,...
by Mckl
Tue Apr 14, 2020 9:45 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

Oh so instead of calculation relative position between vehicle player and some car source(where car is relatively to listener) I can just put listener position and source position.
by Mckl
Tue Apr 14, 2020 8:00 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

Ahh not sure how, should I combine velocities somehow?
by Mckl
Tue Apr 14, 2020 5:20 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

And if listener moving with some velocity should I account for that?
by Mckl
Sun Apr 12, 2020 10:48 pm
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54648

Re: openAl sound

I know I am a little bit ahead on your articles. I am wondering what I should look for when I am making audio sources move?