Reputation: 449
Is it possible to add specific reverb to my sound effect/music track in libgdx? I want to add outdoor/indoor reverb to make all tracks sounded the same.
Upvotes: 2
Views: 584
Reputation: 3274
I've implemented reverb, positional audio, and arbitrary filters using OpenAL against the latest libgdx 1.10+/lwjgl 3+ with this demo code, based off of gdx-sfx (which only works with lwjgl 2) and libgdx-audio-effects.
I'd like to promote this into a fully fledged library at some point 😂
Upvotes: 0
Reputation: 13581
I don't think that Libgdx has a mechanism to adding effects to sound. The Sound class delivers no function for this.
I see three solutions here:
Try to implement it yourself
I see that in the Sound class there is setPitch(long soundId, float pitch)
method. Due to Wikipedia the reverb is just a kind of echo so maybe (but not for sure) you could achieve the effect by
First one is the easiest and if you are not afraid of space problems I would strongly recommend it to you (althought why not to try implementing it)
Upvotes: 4