Bug 3885

Aric Cyr Aric.Cyr at gmail.com
Wed Dec 21 02:22:20 CST 2005

Tom Spear <speeddymon <at> gmail.com> writes:

> Louis also hard coded D3D_OK into wine in the right spot and managed to 
> get the program to go thru all benchmarks from 1-16, so wine is 
> mis-reporting something there.
> If someone could take a look and propose a fix, it would be appreciated, 
> seems to me that the 2 fixes should be fairly trivial to come up with 
> since those 1 line hacks worked to get around the aforementioned problems.

I took a look at the D3D_OK hack, and I believe the problem to be
CheckDeviceFormat in wined3d/directx.c.  This function should return an error if
D3DFMT_D32 is checked for on cards which don't support 32bit depth.  Currently
it just returns OK for most formats though.  This code is really just a stub as
it stands, and needs to be converted to check if there are any visuals that meet
the requested format's requirements, and if there is, return D3D_OK, otherwise

To test my theory, try returning D3D_NOTAVAILABLE for the D3DFMT_D32 case
(you'll need to add it) in wined3d/directx.c in IWineD3DImpl_CheckDeviceFormat()
and see if that fixes that issue or not.  This would be just another hack
though, so a real patch would still be necessary as I decribed above.

- Aric

More information about the wine-devel mailing list