Detect Video Playback
loudermp last edited by loudermp
I started using Vivaldi(which is a great browser I previously used Firefox) in Windows but I recently switched to Linux, I would like to detect if a video is playing in the browser, the reason is I want a way via script or any other programming language to cause some activity or temporarily disable the screen saver so it does not start, it does not in the Windows version and possibly in the Mac version but it does in the Linux version, maybe someone has already figured out how to do this, I also think it would be helpful to developers if Vivaldi kept a file to record what is happening with the browser such as tab names, a video is playing and the video playback technology (such as Flash Player or HTML5 and others), and other things I may not have thought of, some or all of this info may can be gotten from various places but it would be so much easier if one file contained this info.
The best way I have determined so far to detect video playback in the browser is to detect audio which I have implemented but I am still searching because I can see flaws using this method, in case any one else in looking for a solution to this issue here is the command I am currently using which I view as a temporary solution,
$> pacmd list-sink-outputs