Saturday, November 30, 2013

xscreensaver troubles in linux wth mplayer, VLC, mplayer2

I have been noticing screen blanking issues with xscreensaver for some time since the gnome, dbus and mplayer and xscreensaver decided to move  against each other with their decisions on screensaver function and ultimately all I ended was with a system which kept blanking all the time with xscreensaver. I have tried using Fedora 19,20,21 rawhide Arch Linux, Gentoo, Debian wheezy, CentOS with nux repos enabled and all the distros were hit with this issue.

For Mplayer, Mplayer2:

If you happen to look at the xscreensaver FAQs it says to use heartbeat-cmd="xscreensaver-command -deactivate >&- 2>&- &"   in your ~/.mplayer/config and it doesn't work all the time with all the distros. What I have found is the xscreensaver binary is located in a different place from where the mplayer is looking and it ultimately fails to find the xscreensaver. So in your distro find out where the binary is located and point it to right location as I have it here for gentoo unstable as follows.

heartbeat-cmd="/usr/bin/xscreensaver-command -deactivate > /dev/null"


 For VLC:


I have been hunting for a solution for VLC to disable blanking for a long time and I couldn't get a clean way to use vlc without running scripts like lightsOn.sh. or any other wrapper scripts to be running in the background while you are watching videos on VLC until I found a post in Fedora forums which suggests to
create a file called /etc/X11/xorg.conf.d/00-system-dpms.conf and have the contents of the file as follows and after saving the file as root restart X to amend the changes.

 
 Section "ServerFlags"
   Option "BlankTime" "0"
   Option "StandbyTime" "0"
   Option "SuspendTime" "0"
EndSection
 
 
 

No comments: