ddraw: Fix filtering of enumerated display modes by bits per pixel
Ričardas Barkauskas
miegalius at gmail.com
Tue May 10 02:11:56 CDT 2011
On 05/09/2011 10:11 PM, Stefan Dösinger wrote:
> On Monday 09 May 2011 20:55:21 Ričardas Barkauskas wrote:
>> + modes16bpp_cnt = 0;
>> + U2(ddsd.ddpfPixelFormat).dwRBitMask = 0x0000;
>> + U3(ddsd.ddpfPixelFormat).dwGBitMask = 0x0000;
>> + U4(ddsd.ddpfPixelFormat).dwBBitMask = 0x0000;
> Please add an additional test that passes in non-null flags that don't match
> standard R5G6B5.
I'm not exactly sure what you mean with this. The other test has mask of
R5G5B5. The one that's missing is R5G6B5, but I don't think it's needed.
>> + if ((DDSD->dwFlags & DDSD_PIXELFORMAT) && (DDSD-
>> u4.ddpfPixelFormat.dwFlags & DDPF_RGB) )
>> + if(pixelformat.u1.dwRGBBitCount != DDSD-
>> u4.ddpfPixelFormat.u1.dwRGBBitCount) continue;
> For the fun of it you could see what happens when you pass a non-RGB
> format(e.g. a DDPF_YUV or DDPF_BUMPDUDV one) to EnumPixelFormat, but that's
> not really a requirement for me. Afaics the DDPF_RGB check is needed anyway to
> enumerate 8 bit palettized formats properly.
>
> A YUV primary format may even make sense. A BUMPDUDV one not really.
My bad. Didn't think of testing this before. Now it is to strict.
Ricardas Barkauskas
REalm
More information about the wine-devel
mailing list