I've been using the Status text of my MPC-HC window to determine if a video is playing or paused. However, when in Fullscreen mode or when the Status bar is hidden, the Status text does not update. Someone pointed out this bug to the MPC-HC team, but it hasn't been resolved: https://trac.mpc-hc.org/ticket/5640
I've tried using the MPC-HC API to get the state of the media player, but that required I run MPC-HC with the /slave command in order to trigger WM_COPYDATA, which I don't want.
More info on that method here:
media player classic - jump to point in video/audio programmatically
Here's the code I'm using right now. Fails if the Status bar is not visible.
IsMediaPlayerClassicPlaying() {
ControlGetText, vPlayPause, Static3 , ahk_class MediaPlayerClassicW
If InStr(vPlayPause, "Playing")
Return True
Else
Return False
}
I expected the function to return True whenever MPC is playing a video, but it only works if the status bar is visible. It seems that MPC doesn't update the status bar text (Playing/Paused) if it's not visible.