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

Getting audio level instead of slider level #56

Open
JotaFaD opened this issue Jan 8, 2022 · 1 comment
Open

Getting audio level instead of slider level #56

JotaFaD opened this issue Jan 8, 2022 · 1 comment

Comments

@JotaFaD
Copy link

JotaFaD commented Jan 8, 2022

Windows 10 21H1
Python 3.8.3
Pycaw 20181226

To summarize, I'm trying to check if an app is attempting to play audio, even if the session is muted.

The windows audio mixer shows a grey bar representing the maximum audio output when an app is playing, even if the slider for that application would not allow it to reach that level. Is there any function that can retrieve the value of this grey bar instead of the current value of the slider?
Audio Level

@TJ-59
Copy link

TJ-59 commented Sep 23, 2024

If you're speaking of the horizontal bar, probably the device's EndpointVolume.GetMasterVolumeLevelScalar().
But I fail to see the link with to check if an app is attempting to play audio, even if the session is muted .
Maybe the app's session State is what you seek, going from 0 (inactive) to 1 (active), depending on the app using it or not. But keep in mind it does not necessarily means the app is actually sending audio.
If you are talking about the vertical bar, showing the current "peak" of the sound level, it's an ever moving value, and you'd need to use IAudioMeterInformation 's GetPeakValue.

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