Dear Fmod developers,
recently i encountered a really bad problem in m audio application. Some times it drops out when I do to much load in the UI. Actually, this can be achived by sleeps and so on but some users might have older PCs so I really like to sort this out at the right level.
- CPU-Killer 3 Demo (http://www.cpukiller.com/)
- PlaySound Example from FMOD-Package.
I start up CPU Killer and PlaySound. The I setup up CPU-Killer to 30% and press "Start". CPU usage goes higher. After that I play back a software (hardware sound makes no difference) sound in playsound. What I hear ist droppping sounds.
Well, ok CPU usage might consume the buffer so I check against several other Audio engines like Bass and none of them even has a single drop out at 30%. Furthermore I can move the slider up to 99% and the sound is still stable.
So no the question. Is there a possibility to tune the Mixing Threads? I understand for a game, sound isn’t that important like it is for a sound software. I hope you can help me out. I really don’t want to increase the process priority.
with kind regards
- lemart asked 6 years ago
Eventually, I found the problem 😆
The problem seems to be WASAPI. Since this is system default since late 2009 I thought it has been intesivly tested so I left AUTODETECT when I read this behavoiur was changed in FMODEx.
Nevertheless it is cause trouble described above.
After intesive research (setting up new system prios and so on), increasing buffers and all of them didn’t really work out I came to the system preferences dialog in Windows Vista. I press on "play sound" and simulatously I consumed CPU with cpukiller. To my surprise I found the same behaviour in windows itself. Therefore I ran some further tests with different audio engines and software tools and I found WASAPI is NOT reliable. DirectSound is reliable even in thos weird circumstances.
So, I switched to DirectSound and I am almost happy with it, but I really like to understand the decision to switch from DirectSound to WASAPI. Could you please share us your intention?
- lemart answered 6 years ago
It looks like CPU Killer is running multiple ‘time critical’ threads which is starving out FMOD. The fact that while running CPU Killer the Windows sounds stutter means the issue probably isn’t FMOD specific.
On Vista / Windows 7 DirectSound is emulated and run on top of WASAPI with extra buffering hence why we have switched to WASAPI. I’m not sure that CPU Killer is a good indication of testing reliability, however you are free to force FMOD to use DirectSound as its output mode.
Please login first to submit.