Allow computer to sleep while playing audio from a Windows application
0 1 I am working on a Windows 10 application that plays audio in the background. What I would like to be able to do is allow the computer to still go in to Sleep Mode while the audio is playing (as in, Power & Sleep Settings, Sleep after XX minutes). And by this, I mean stop playing the audio and go to Sleep (not continue playing while in Sleep). Is this even possible? Searching online hasn't been fruitful, as I can pretty much only find information on how to prevent Sleep, not enable it. Running powercfg.exe /requests shows the audio playback is indeed preventing sleep: SYSTEM: [DRIVER] Realtek High Definition Audio (...) An audio stream is currently in use. I am currently using the IAudioClient and IAudioRenderClient interfaces for playback, via client->Start(), renderClient->GetBuffer(). I could switch to a different API if necessary. However, whatever I use needs to allow other applications (VLC, YouTube, Windows sounds, etc.) to play audio as normal at