-
Notifications
You must be signed in to change notification settings - Fork 535
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Looping sound won't stop mid-loop #995
Comments
@kcat By any chance, might Try to fix EAX obstruction, occlusion, and exclusion help this? I'm gonna try to 'test' this over the weekend, if the wife will let me. 😹 |
I doubt it, it doesn't really have anything to do with sounds stopping. Out of curiosity, for the expected behavior, what is that using? Is it DirectSound instead of OpenAL? Or some internal sound mixer/processor? I think the information I could get about this suggested that it may be an issue with the way the game uses OpenAL when a looping sound should stop; it disables looping on the source and leaves it to stop on its own, rather than being explicitly stopped. There's nothing OpenAL Soft would be able to do in that case, if that's the actual problem. It may be helpful to compare to Generic Software or some OpenAL hardware driver, if the game can be made to use them. |
The BF2 default uses Creative's OpenAL32.dll renamed to BF2OpenAL.dll (Creative Labs OpenAL32, v2.1.8.1, Copyright 2007, US). Fwiw, the audio engine is SoundEngine.dll renamed to BF2Audio.dll (BF2 SoundEngine, v1.0.0.1, Copyright 2003, Sweden). |
While I'm not a programmer, I managed to build the dll from the then latest commit https://github.com/kcat/openal-soft/tree/a2a7e268bed0581a6739349ed34d2ccb5260d405 (
Like previous poster said, BF2 uses what seems to be a renamed OpenAL.dll, and OpenAL Soft works as a drop-in replacement. In fact, various combinations of normal or router version of BF2 also supports DirectSound. Thus dsoal can be used as a locally loaded version of |
When playing old Battlefield 2 based games or mods with OpenAL Soft, some looping sounds never stop mid-loop. E.g. vehicle engine sound keeps playing for a while after exiting the vehicle. This happens with unmodified game and also with mods built for the same Refractor 2 game engine.
Please see the following videos for examples.
Expected: Engine sound stops immediately upon exit
https://1drv.ms/v/s!AnhtECQ4lmzWgZkI29z4-R7cVRX6LQ?e=I9qIvd
Actual: Engine sound keeps playing for a couple of seconds
https://1drv.ms/v/s!AnhtECQ4lmzWgZkHbvDqzVBjX7i5MA?e=D3uvyt
Log:
The text was updated successfully, but these errors were encountered: