Bug #269

xscreensaver does not respond to commands under R6

Added by graysky over 15 years ago. Updated almost 13 years ago.

Status:Closed Start date:
Priority:Normal Due date:12/31/1969
Assignee:jams % Done:

0%

Category:- Spent time: -
Target version:6.00.04

Description

I installed xscreensaver from the LinHES repo and added the following to my ~/.fluxbox/apps to start it:

[startup] {xscreensaver}

It works fine in that it will come on at the pre-determined time and it will stop if I use my keyboard/mouse. The problem is that it doesn't respond to xscreensaver-command -deactivate which as you know is needed to keep it coming on when mplayer is playing.

I tried the following from a shell:

$ xscreensaver-command -deactivate <<<there is a 10-15 sec pause>>> xscreensaver-command: no response to command.

I know that xscreensaver is running because I see it in my ps aux command and I also see the splash screen load when X comes up. Finally, I know it's running because it turns on after 10 min :)

If I do the same command from a shell under R5.5, I get an instantaneous response to the command (i.e. there is no pause) and it answers:

$ xscreensaver-command -deactivate xscreensaver-command: not active: idle timer reset.

This is important because mplayer gets all wacked out - see [[http://knoppmyth.net/flyspray/index.php?do=details&task_id=268|task 268]] for more on this. I believe the problem described in #268 is a symptom of this problem.


Related issues

related to LinHES - Bug #268: problem with mplayer-vdpau-nogui and xscreensaver Closed
related to LinHES - Bug #273: xscreensaver ignores keyboard/mouse/remote commands to re... Closed 12/31/1969

History

Updated by graysky over 15 years ago

I'm pretty sure this is an xscreensaver bug. I emailed jamie and will update this task when I hear back from him.

Updated by graysky over 15 years ago

Well, the temp fix for keeping xscreensaver deactivated while mplayer is playing a file is to add the following to your ~/.mplayer/config

heartbeat-cmd="xscreensaver-command -deactivate &"

I am unhappy to report that this works some of the time, but not all of the time. I successfully played two 40-50 min files with no problems, but the third file did have a problem. I didn't see the xscreensaver start (using pyro) but the video did freeze while the audio kept playing. I believe xscreensaver is to blame but I'm not 100 % certain.

I have two questions/proposed solutions:

1) Can we use v5.04 of xscreensaver (this is what R5.5 uses and this version replies to the heartbeat command just fine under R5.5)?
or

2) Is there an alternative screensaver that plays well with mplayer?

Updated by jams over 15 years ago

5.0.4 does not compile with newer versions of gcc, and 5.0.7+ show the same behaviour.

Updated by graysky over 15 years ago

Damn. I haven't heard back from jamie regarding the bug. Maybe my domain [yahoo.com] is blocked? Here is the content of the email if you wanna try it from your account:

Hello, I'm running a distro based on Arch Linux and version 5.08 of xscreensaver which I obtained from the official arch linux repo. Here is the problem: when I issue the following command 'xscreensaver-command -deactivate' from a shell, it hangs for 10-15 sec and then answers with 'xscreensaver-command: no response to command.' This is in contrast to my debian box. When I enter the same command there, I get, 'xscreensaver-command: not active: idle timer reset.' and that comes up instantly. The version of xscreensaver running on my debian box is 5.04 so it's different. Is this a bug in 5.08? I think this is a problem with xscreensaver: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=486603 Thank you and warm regards.

Updated by jams over 15 years ago

gnome-screensaver is now in the repo. Please see if this works any better. My own limited testing shows that it works as expected.

Updated by graysky over 15 years ago

You read my mind! I was going to ask if GSS would work under fluxbox.

Here is what I've done to test this:

1) disabled xscreensaver (Service>Advanced>3rd page)
2) pacman -Syu && pacman -S gnome-screensaver
3) I ran gnome-screensaver-preferences and unchecked the 'lock screen' tab and lowered the threshold to 1 min for testing purposes
4) Ran gnome-screensaver

At this point, I just left that box idle and indeed floating gnome feet came up.

5) I added the following to my ~/.mplayer/config

heartbeat-cmd="gnome-screensaver-command -p &"

Mixed results.

Test #1: Started mythfrontend and used the remote to start a vid (I use mplayer-resumer-vdpau.pl %s in my mplayer config).
Result #1: It worked. Gnome-screensaver did not activate until I stopped using mplayer and the 1 min timer ran out.

Test #2: Left mythfrontend idle until gnome-screensaver started
Result #2: only keyboard/mouse can wakeup gnome-screensaver; my ati remote wonder could not

Test #3: Played a captured video through the internal player
Result #3: gnome-screensaver started during playback

So: It works with mplayer, it doesn't work with lirc, and it doesn't work with the internal mythtv player.

Updated by jams over 15 years ago

New packages in place, please give them a try.
They work as expected here, including using a remote via lirc. I have not tested anything with mplayer.

mythtv
gnome-screensaver
LinHES-system
LinHES-config

Be sure to uninstall xscreensaver, and that the official mythtv packages are used and NOT vdpau.

Updated by graysky over 15 years ago

pacman -Syu pacman -R xscreensaver pacman -Rd mythtv-vdpau pacman -S mythtv gnome-screensaver LinHES-system LinHES-config

I'll give it a try tomorrow when I have more time and report back.... btw, I noticed there's a newer xscreensaver package in the repo?

Updated by nickca over 15 years ago

gnome-screensaver is mostly working properly on my system (responds to LIRC events in MythTV menu and in mplayer, etc.) although not any better than xscreensaver had been since the 5.08-2 update, which seemed to mostly fix things. In fact, the screensaver briefly activated for a few seconds while playing a video with mplayer. It deactivated in a second or two, but that never happened with xscreensaver. Also, I've only seen one type of screensaver so far (various astronomy pictures), which is kind of boring.

Updated by graysky over 15 years ago

You can pick a few others via:

$ gnome-screensaver-preferences

My guess is that Jams can add the rest of them once we know GSS is a viable alternative to XSS moving forward. There are many options for others judging by what is installed on my Ubuntu box.

Updated by graysky over 15 years ago

Jams - mixed results with the new packages.
About 1 h ago, I updated the system, rebooted, and gave it a try:

While watching a captured show on the internal player, GSS came on. (Three out of three times)
While watching stuff in mplayer, GSS did NOT come on (I have the following line in my ~/.mplayer/config: heartbeat-cmd="gnome-screensaver-command -p &"
GSS does respond to some of the buttons on my remote, but not all of them.

Updated by jams over 15 years ago

The screensaver timeout is greater then or equal to 2 minutes?
myth will only send the poke command every 60 seconds, so it's possible that the screensaver will kick in if the timeout is set to 1 minute.

Updated by graysky over 15 years ago

@jams - yeah, mine is set to 1 min for testing purposes... looks like that might be to blame. I will up it to 3 min and retest and report back.

Updated by nickca over 15 years ago

OK, the quickly-activate-then-deactivate thing while playing videos with mplayer happened often enough to get pretty annoying. I've switched back to xscreensaver, and it's been working perfectly. I still see "no response to command" messages in the frontend log while using mplayer, but as long as I add the "&" to the end of heartbeat-cmd, it still never exhibits the freeze-every-30-seconds behavior. Plus, xscreensaver doesn't require a bunch of GNOME dependencies that aren't used for anything else.

Updated by graysky over 15 years ago

@Nick - I dunno, if it happens 1 of out 20 times, that's still too frequent in my book.

Updated by nickca over 15 years ago

It happens, but it doesn't affect anything as long as you set "xscreensaver-command -deactivate &" as mplayer's heartbeat-cmd. Xscreensaver, since the 5.08-2 update, always deactivates on LIRC events and never activates while playing a video. Gnome-screensaver deactivates on events, but it does occasionally briefly activate itself from mplayer and doesn't stay deactivated when using the internal player (according to you above, I don't use the internal player for anything).

Has anyone else experienced the quick-activate-then-deactivate behavior with gnome-screensaver and mplayer? What happens is the screensaver activates despite the heartbeat-cmd, then deactivates right after the fade-out. It happened frequently enough to me to make it unusable.

If gnome-screensaver is accepted for use, could we at least have the option to use xscreensaver instead?

Updated by graysky over 15 years ago

@Nick - I'm sure they won't remove xscreensaver from the repo - the general attitude from cesman and from other folks is that it's your box. If you search around in the forums, you'll see examples of this. XFS on /myth for example.

Updated by jams over 15 years ago

Both gnome-screensaver and xscreensaver are available and supported in the service menu(for myth, not mplayer).
The xscreensaver timeout appears to be upstream bug that nobody wants to admit is present.

Updated by graysky over 15 years ago

Cool, I updated my packages, but I didn't see an option under the service menu to allow the user to select either XSS or GSS.

Updated by nickca over 15 years ago

The new screensaver-choosing facility is great! This is the best solution, allowing the users to choose.

Is there a reason why the configuration script doesn't just add the proper lines to the mplayer configuration? It would only need to add (to ~/.mplayer/config)

stop-xscreensaver = 1 (for both)
heartbeat-cmd="/usr/bin/xscreensaver-command -deactivate &" (for XSS)
heartbeat-cmd="/usr/bin/gnome-screensaver-command --deactivate &" (for GSS)

Changing between them could be accomplished with a sed command. I believe I posted an example of how to do something like this in one of these screensaver-related tickets. It's not a big deal if adding something like this is a pain, as it's easy enough to just add the proper lines to mplayer's config, but a less knowledgeable user might not know to do this. I could probably even do this myself if no one else wants to, and post a diff here as a ticket.

@graysky: it's definitely there, in the same place as the old screensaver stuff (Advanced Options). There's a dropdown allowing you to select the screensaver type.

Updated by cecil over 15 years ago

stop-xscreensaver = 1

Does not work for me w/ xscreensaver. xscreensaver works for me w/ both MythTV and MPlayer. gnome-screensaver only work for MPlayer for me... I'll updated the screensaver packages to add themselves to mplayer's config file.

Updated by jams almost 13 years ago

  • Target version changed from 7.2 to 6.00.04

Also available in: Atom PDF