# DPMS problems

**URL:** <https://discourse.libsdl.org/t/dpms-problems/3427>\
**Category:** SDL Development\
**Created:** [November 6, 2000, 5:43pm UTC](https://discourse.libsdl.org/t/dpms-problems/3427 "2000-11-06T17:43:10Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Torbjorn\_Andersson](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/t/a183cd/32.png) [@Torbjorn\_Andersson](https://discourse.libsdl.org/u/Torbjorn_Andersson)\
**Post date:** [November 6, 2000, 5:43pm UTC](https://discourse.libsdl.org/t/dpms-problems/3427/1 "2000-11-06T17:43:10Z")

</div>

I recently discovered and turned on the DPMS option in the X server, i.e. if  
I leave it unattended for long enough the monitor goes into “standby” mode  
(later followed by “suspend” and “off”, but I’m not sure what the difference  
is). However, I noticed that when running some SDL games - including some I  
compiled myself against SDL 1.1.6 - DPMS would kick in in mid-play. The  
monitor wakes up if a press a key, but moving or clicking the mouse is not  
enough. (I first noticed this when playing Heroes of Might and Magic III,  
which is a point-and-click sort of game.)

Is this a problem with X - I’m using the Debian XFree86 4.0.1 packages which  
are based on the 4.0.1d snapshot - or with SDL? Is there a workaround, or  
should I just turn DPMS off while playing?

Torbj?rn Andersson

---

<div class="post-metadata">

**Author:** ![Mattias\_Engdegard](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/m/49beb7/32.png) [@Mattias\_Engdegard](https://discourse.libsdl.org/u/Mattias_Engdegard)\
**Post date:** [November 6, 2000, 6:17pm UTC](https://discourse.libsdl.org/t/dpms-problems/3427/2 "2000-11-06T18:17:29Z")

</div>

> However, I noticed that when running some SDL games - including some I  
> compiled myself against SDL 1.1.6 - DPMS would kick in in mid-play. The  
> monitor wakes up if a press a key, but moving or clicking the mouse is not  
> enough.

This sounds like a definite bug in the X server. The X11 screen saver  
normally kicks in after a preset time interval without any device  
events (keyboard, mouse etc), so your DPMS handler should do the same

---

<div class="post-metadata">

**Author:** ![slouken](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/s/ec9cab/32.png) [@slouken](https://discourse.libsdl.org/u/slouken)\
**Post date:** [November 7, 2000, 4:07am UTC](https://discourse.libsdl.org/t/dpms-problems/3427/3 "2000-11-07T04:07:54Z")

</div>

> > However, I noticed that when running some SDL games - including some I  
> > compiled myself against SDL 1.1.6 - DPMS would kick in in mid-play. The  
> > monitor wakes up if a press a key, but moving or clicking the mouse is not  
> > enough.

> This sounds like a definite bug in the X server. The X11 screen saver  
> normally kicks in after a preset time interval without any device  
> events (keyboard, mouse etc), so your DPMS handler should do the same

Although it’s possible that DGA mouse events don’t kick the X server  
in the pants. You might report this to the XFree86 development group.  
Check out [http://www.xfree86.org/](http://www.xfree86.org/)

See ya!  
-Sam Lantinga, Lead Programmer, Loki Entertainment Software

---

<div class="post-metadata">

**Author:** ![Torbjorn\_Andersson](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/t/a183cd/32.png) [@Torbjorn\_Andersson](https://discourse.libsdl.org/u/Torbjorn_Andersson)\
**Post date:** [November 9, 2000, 4:24pm UTC](https://discourse.libsdl.org/t/dpms-problems/3427/4 "2000-11-09T16:24:40Z")

</div>

(I hope this one will only be sent once this time.)

> Although it’s possible that DGA mouse events don’t kick the X server  
> in the pants. You might report this to the XFree86 development group.  
> Check out [http://www.xfree86.org/](http://www.xfree86.org/)

I guess this would be a good time to admit that I don’t know the  
difference between a DGA mouse event and common, garden-variety mouse  
event. You may be right, though. If I set SDL\_VIDEO\_X11\_DGAMOUSE to 0  
DPMS works as expected.

So I guess I should write up a bug report and send to the XFree86  
developers. I just wish I’d understand half of it myself first. 😉

Torbj?rn Andersson
