Re: [PATCH] Also show 24bit modes as supported, but still handle them like 32bit later

2006-09-27 Thread Vitaliy Margolen
Christoph Frick wrote:
> hi
> 
> would someone please comment on that patch? this is a nearly unchanged
> version of my previous attempt - but this time against current git.
> 
> -static const unsigned int depths[]  = {8, 16, 32};
> +static const unsigned int depths[]  = {8, 16, 32, 24};
> +static const unsigned int nr_depths = sizeof(depths) / sizeof(depths[0]);
>  
Can you make a test that demonstrates presence of 24-bit color depth on
native? I have checked winnt40, win2k, winxp and none offering 24-bit.

Also I seen some programs and games that will crash if you tell them
that we really in 24-bit (as most X users are).

Vitaliy.




Re: [PATCH] Also show 24bit modes as supported, but still handle them like 32bit later

2006-09-27 Thread Stefan Dösinger
Hi,
> would someone please comment on that patch? this is a nearly unchanged
> version of my previous attempt - but this time against current git.
Not so sure about it. I am afraid I do not completely understand the color 
depth issue, but it appears to me that a patch like that rather hides the 
problem than fixing it.

It is not possible to chance the depth on the fly on X11, so we may want a 
solution for all color depths.


pgpZH8wkEvEJp.pgp
Description: PGP signature



[PATCH] Also show 24bit modes as supported, but still handle them like 32bit later

2006-09-14 Thread Christoph Frick
hi

would someone please comment on that patch? this is a nearly unchanged
version of my previous attempt - but this time against current git.

---
 dlls/winex11.drv/settings.c |9 -
 1 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/dlls/winex11.drv/settings.c b/dlls/winex11.drv/settings.c
index 5de07eb..c9bced2 100644
--- a/dlls/winex11.drv/settings.c
+++ b/dlls/winex11.drv/settings.c
@@ -39,7 +39,8 @@ static LPDDHALMODEINFO dd_modes = NULL;
 static unsigned int dd_mode_count = 0;
 static unsigned int dd_max_modes = 0;
 static int dd_mode_default = 0;
-static const unsigned int depths[]  = {8, 16, 32};
+static const unsigned int depths[]  = {8, 16, 32, 24};
+static const unsigned int nr_depths = sizeof(depths) / sizeof(depths[0]);
 
 /* pointers to functions that actually do the hard stuff */
 static int (*pGetCurrentMode)(void);
@@ -62,7 +63,7 @@ LPDDHALMODEINFO X11DRV_Settings_SetHandl
 TRACE("Resolution settings now handled by: %s\n", name);
 if (reserve_depths)
 /* leave room for other depths */
-dd_max_modes = (3+1)*(nmodes);
+dd_max_modes = nr_depths*nmodes;
 else 
 dd_max_modes = nmodes;
 
@@ -111,7 +112,7 @@ void X11DRV_Settings_AddDepthModes(void)
 int existing_modes = dd_mode_count;
 DWORD dwBpp = screen_depth;
 if (dwBpp == 24) dwBpp = 32;
-for (j=0; j<3; j++)
+for (j=0; jdmDisplayFlags = 0;
 devmode->dmDisplayFrequency = 0;
 devmode->dmSize = sizeof(DEVMODEW);
-- 
1.4.2