[MPlayer-dev-eng] vo_x11.c: vm

Uwe Reder Uwe.Reder at 3SOFT.de
Thu Oct 4 11:26:25 CEST 2001


Hello!

I subscribed to the mailing list to send a patch that improves vm-fullscreen 
in vo_x11. In vm-fullscreen it was easy to move the video out of the visible 
screen (view port) by touching the mouse. Moreover, even on startup the video 
was not fully centered.

This patch solves the problems by grabbing the mouse pointer and disabling 
window decoration. The file to patch (agains MPlayer-0.50-pre1) is 
libvo/vo_x11.c.

If you have any questions, pls don't hesitate to ask!

Thanks,
Uwe.


151a152
>  unsigned int modeline_width, modeline_height;
185c186
<         unsigned int modeline_width, modeline_height, vm_event, vm_error;
---
>         unsigned int vm_event, vm_error;
229c230,239
< 
---
> #ifdef HAVE_XF86VM
>     if ( vm )
>      {
>       hint.x=(vo_screenwidth-modeline_width)/2;
>       hint.y=(vo_screenheight-modeline_height)/2;
>       hint.width=modeline_width;
>       hint.height=modeline_height;
>      }
>     else
> #endif
246c256
<     xswa.border_pixel=1;
---
>     xswa.border_pixel=0;
248c258
<     xswamask=CWBackPixel | CWBorderPixel |CWColormap;
---
>     xswamask=CWBackPixel | CWBorderPixel | CWColormap;
249a260,267
> #ifdef HAVE_XF86VM
>     if ( vm )
>      {
>       xswa.override_redirect=True;
>       xswamask|=CWOverrideRedirect;
>      }
> #endif
>  
253a272
> 
265d283
< 
266a285,295
> 
> #ifdef HAVE_XF86VM
>     if ( vm )
>      {
>       /* Grab the mouse pointer in our window */
>       XGrabPointer(mDisplay, mywindow, True, 0,
>                    GrabModeAsync, GrabModeAsync,
>                    mywindow, None, CurrentTime);
>       XSetInputFocus(mDisplay, mywindow, RevertToNone, CurrentTime);
>      }
> #endif

-- 
  ---------------------------------------------------- 
  Uwe Reder, Dipl.-Inf. (Univ.), mobile applications
  3SOFT GmbH, Frauenweiherstr. 14, 91058 Erlangen, Germany
  Tel. +49-9131-7701-133   mailto:Uwe.Reder at 3SOFT.de
  Fax +49-9131-7701-333    http://www.3SOFT.de




More information about the MPlayer-dev-eng mailing list