While debugging one of my Windows Phone applications on the device I've noticed that after the debug session the battery of the device drained faster than usual (so I always restarted the device after using it for debugging). Initially I thought it was the Bluetooth driver but I saw that if I stop the XAudio2 engine when my application gets suspended and re-enable it when the application resumes my battery drains "normally". This should be a best practice as your application doesn't really need the engine when it gets suspended. So:
- When your app is suspended, call IXAudio2::StopEngine.
- When your app is resumed, call IXAudio2::StartEngine.
NAMASTE
No comments:
Post a Comment