Skip to content
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

Win32 application crash with equalizer effect #738

Closed
Lulu04 opened this issue Jul 20, 2022 · 3 comments
Closed

Win32 application crash with equalizer effect #738

Lulu04 opened this issue Jul 20, 2022 · 3 comments

Comments

@Lulu04
Copy link

Lulu04 commented Jul 20, 2022

Hi, I have translated OpenAL-Soft header to FreePascal and write some demos to the pascal community.
This demos are tested under Windows and Linux, 32 and 64bits.

All works well until in one of this demo I use Equalizer effect:
On Win32 application sometime crash, sometime not. Application that use equalizer never crash under Win64, Linux32 nor Linux64.

First, I thought that the problem was with the pascal code layer. To eliminate this possible cause, I added the use of equalizer effect in one of the C example provided with OpenAL-Soft -> altonegen.c

On my Win7 32bits old computer, the transformed altonegen some time crash, sometime not.
The DLL used to make the test is from https://openal-soft.org/openal-binaries/openal-soft-1.22.2-bin.zip

In the attached ZIP file, you will found the transformed altonegen.c, one log file with crash, one without and the result of openal-info.
Thanks for your time.

Win32EqualizerCrashTest.zip

@Lulu04
Copy link
Author

Lulu04 commented Jul 26, 2022

I forgot to mention that all the other effects proposed by the extension work very well, both in 64 and 32 bits.

In the transformed altonegen.c, we creates 60 equalizer effects, this have no sense, it's only to do an intensive use of it.
Only the first is attached to the source.
If you have time and the possibility to compile on a win32 machine, could you test it ? Just to see if the crash also appears.
Here, the average is 5 crashes on 10 tries.
Regards

@kcat
Copy link
Owner

kcat commented Jul 26, 2022

If you're able, try now with commit f35eb64. The equalizer's processing buffer wasn't explicitly aligned, so depending on the allocated address for the effect object, it could end up unaligned and crash when trying to use SSE with it.

@Lulu04
Copy link
Author

Lulu04 commented Jul 26, 2022

Well done, crash not appears any more ! Thanks you very much and 'bravo' for your efficiency !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants