[MPlayer-users] X Screen resolution detection with multi-head xinerama.
daniel carter
hedonist at win.co.nz
Thu Dec 13 13:48:12 CET 2001
daniel carter wrote:
> When displaying the movie on the TV, it detects the display as 1024x768
> which messes up the scaling because the screen is only 800x600 so the
> right edge and bottom part of the movie are not displayed.
>
>
> now i can change that to
> vo_screenwidth=screens[1].width;
> vo_screenheight=screens[1].height;
> and my problem is solved, until i want to watch something fullscreen on
> my CRT and i have to recompile mplayer :(
>
OK, AFAICT there is no way for an application to easily detect which
xinerama screen a window it creates will be placed on (there is only one X
screen under xinerama)
So, i've hacked away at mplayer a bit and here is what i've got working:
I've put in a new commandline parameter -xineramascreen that takes a screen
number.
This is used for two purposes.
1) When calculating the screen width and height, it uses the screen
specified rather than the current behaviour of using the first screen.
2) When creating a window, instead of opening the window at 0,0 (upper left
of the first screen) it places it in the upper left of the screen specified.
So ,under window managers such as window maker where there was previously no
way to make the window display on a certain screen, you can now make it
display on certain screen.
Under KDE, the window is always displayed on the screen with the mouse
pointer, overriding what is specified, but when displaying fullscreen using
-fsmode 1 it is now displayed on the screen specified rather than always on
the first screen.
Should i send a patch in?
More information about the MPlayer-users
mailing list