Hi,
This is probably and FAQ but.... I have a game here that bails on startup saying that I should change my colour depth to 32 bits. Problem is, X has no concept of this colour depth. How does that work?
thanks -mike
This is probably and FAQ but.... I have a game here that bails on startup saying that I should change my colour depth to 32 bits. Problem is, X has no concept of this colour depth. How does that work?
Does it bail after some DDraw calls ? If it's DDraw, it's strange as we should report both 24 and 32 BPP (after my complaining to Alex in his resolution change patch).
Now if it does the check using standard Win32 API, I remember 'fixing' something like that for a guy on IRC, but I cannot remember exactly where (from what I remember, there is a BPP parameter stored somewhere in the various sys-metrics or device caps do not remember which but a +relay trace would help).
And, of course, Wine reports Depth whereas Windows expect BPP (and despite a lot of tries, we never managed to really find a proper way to distinguish 24/24 modes from 24/32 modes using standard X calls).
If you find the place, I think putting 32 always when the depth of X is 24 would be good for 99.99 % of the people using Wine on current desktops.
Lionel
On Sun, Dec 28, 2003 at 11:35:53AM +0100, Lionel Ulmer wrote:
Now if it does the check using standard Win32 API, I remember 'fixing' something like that for a guy on IRC, but I cannot remember exactly where (from what I remember, there is a BPP parameter stored somewhere in the various sys-metrics or device caps do not remember which but a +relay trace would help).
After some more grepping in the code, I think I fixed this in dlls/x11drv/init.c by changing the BITSPIXEL case of the X11DRV_GetDeviceCaps function by something like
'(screen_depth == 24 ? 32 : screen_depth)'
Note that a check for regressions needs to be done as this value may also be used by DIBs and other stuff.
Lionel
On Sun, 2003-12-28 at 10:43, Lionel Ulmer wrote:
After some more grepping in the code, I think I fixed this in dlls/x11drv/init.c by changing the BITSPIXEL case of the X11DRV_GetDeviceCaps function by something like
'(screen_depth == 24 ? 32 : screen_depth)'
Note that a check for regressions needs to be done as this value may also be used by DIBs and other stuff.
This didn't fix the problem and caused lots of err messages like this:
err:x11drv:X11DRV_CreateBitmap Trying to make bitmap with planes=1, bpp=32
I'll investigate a bit further.
On Sun, 2003-12-28 at 10:35, Lionel Ulmer wrote:
Does it bail after some DDraw calls ? If it's DDraw, it's strange as we should report both 24 and 32 BPP (after my complaining to Alex in his resolution change patch).
No, it appears to use ChoosePixelFormat and the related function that I forgot the name of (I was examining the relay last night).
thanks -mike