Can only hear sound if headphone is inserted before exe launch.

(Darkey) #1

When I first time launch my exe, not any headphone or other sound device is connected.Then I try to insert headphone, but no sound. I need to restart my exe. I guess it is because when fmod first init, it detect no device, then run on silent mode,even if I insert headphone later.
Maybe I can detect the headphone is connected and reinit fmod or other better way?

I already know it is about sound driver realtek.If I uninstall it, every thing is OK.

(Mathew Block) #2

One way to handle the ‘no devices at launch’ issue is to use System::setCallback and watch for device list changed events. This will tell you when something has been attached that will allow output.