iphoneopenal

How to adjust the volume of a sound in OpenAL?


How can I adjust the volume of a sound in the OpenAL sound library?


Solution

  • float newVolume = 0.4f;
    alSourcef(currentSourceID, AL_GAIN, newVolume);