different approach to resolution switching

Dustin Navea speeddymon at yahoo.com
Tue Sep 9 20:09:07 CDT 2003

--- Rok Mandeljc <rok.mandeljc at gimb.org> wrote:
> I've been thinking recently about resolution changes in wine/X. As I
> understand, this now works with UseXVidMode enabled, but I sometimes
> find it ugly; I run X at 1280x1024 and when I run game in 640x480
> (fullscreen), X switches resolution. But as mouse cursor can escape from
> 640x480 "box", I can see the rest of my desktop (enlarged). I believe
> this is not how Win do it.

Actually, you are right, in a sense.  That isnt how windows does it.  The
game developers are the ones that decide how they want the in-game resolution
to be done..  IOW: Yes windows handles the code to change resolution, but the
game chooses the method..

I know for a fact that in some games, they change the resolution of the
entire desktop (just alt-tab out of the game enough times and you will see
your desktop in 640x480 or 800x600), while in others they do something else
(my guess would be enlarging the game window)..

The reason you cant escape the game's window in Windows is 1 of 2 reasons (im
not sure which is the one actually used, or maybe both apply).

The first would be because DirectX grabs the mouse and locks it into the
dx-created window, although i think the 2nd one is the actual reason, this
could be it..

The 2nd would be the way windows handles resolutions..  In windows,
everything gets larger except for the desktop space..  Your icons and the
taskbar take up more room, but you cant scroll the desktop to see everything
(thats why if you are in 800x600 and have icons on the far right, when you go
to 640x480, you can't see them anymore)..  So no desktop scrolling in

In X, everything grows, the area of the desktop, as well as everything on it,
and you can scroll to see it all.  Since wine doesnt always grab the mouse
(and dxgrab doesnt always do what its supposed to), you are able to go
outside the game window and see your desktop in the game's resolution, which
isnt always what you want...  Hopefully DXGrab works for those games..

> Even worse is when you run a game in desktop mode (let's say 1024x768)
> and game uses different resolutions (e.g. game: 1024x768, intro & main
> menu: 640x480).
> So I've been wondering if you guys have already considered use of
> scaler. It would probably (in my opinion) look much nicer than current
> res switching and it would fill those black places in desktop mode.

I agree here, this would be a nice bug-ger (feature)... ;)  The problem would
be that at first it would probably end up using a lot of magic numbers, until
we figured out what went there and it probably wouldnt work for a lot of
games until we tweaked the code, but it would be better than nothing.. 
Another benefit would be for apps that for some reason dont take up all of
the desktop window even when maximized (i seem to remember there being a
couple, but it's been so long I dont remember which ones)

Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software

More information about the wine-devel mailing list