[MPlayer-dev-eng] [PATCH] Let vo directx survive screensaver

Sascha Sommer saschasommer at freenet.de
Sun Oct 29 14:04:29 CET 2006


Hi,

On Sunday 29 October 2006 10:19, Reimar Döffinger wrote:
> Hello,
>
> On Sun, Oct 29, 2006 at 10:19:07AM +0100, Reimar D?ffinger wrote:
> > On Mon, Oct 23, 2006 at 01:05:48PM +0800, Zuxy Meng wrote:
> > > Currently vo directx will crash with seg fault when a screensaver
> > > starts, while vo gl, vo gl2, vo sdl work fine. The root cause is that
> > > when this happens, the last line of flip_page() will set image = NULL.
> > > This patch enables vo directx to survive a screensaver, a monitor off,
> > > a standby and a hibernation, either full screen or windowed, active or
> > > inactive. But there's still one situation that it can't handle: if
> > > mplayer starts to play a file while the screensaver is running,
> > > mplayer won't wake the computer up and once the screensaver exits,
> > > mplayer will have a black window.
> >
> > Can you test this? It is at least as ugly but more straightforward,
> > if it works this while-loop should probably be a separate function and
> > all lock calls replaced by it.
>
> Patch here *g*
>

I do not like this patch. If I understand this correctly ( I'm not able to 
test at the moment ) locking will always fail when the screensave is on, no?
With your patch vo directx will block for the whole time the screensaver is 
on. I do not see a reason why the audio shouldn't be playing in the 
background even though the screensaver is running, but then I thought we 
disable the screensaver somewhere in vo directx...



Btw. in Zuxys patch

@@ -679,7 +679,7 @@
         dwUpdateFlags = DDOVER_SHOW | DDOVER_DDFX;
         /*if hardware can't do colorkeying set the window on top*/
 		if(capsDrv.dwCKeyCaps & DDCKEYCAPS_DESTOVERLAY) dwUpdateFlags |= 
DDOVER_KEYDESTOVERRIDE;
-        else vo_ontop = 1;
+        else if (image) vo_ontop = 1;
 	}
     else
     {

Why is this needed?


Regards

Sascha


 



More information about the MPlayer-dev-eng mailing list