-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Hi,
First of all, thanks for your endurance with this. I know our pickiness can be exhausting.
Am 2014-10-30 19:39, schrieb Patrick Rudolph:
- ddcaps.dwSize = sizeof(DDCAPS);
- hr = IDirectDraw_GetCaps(ddraw, &ddcaps, NULL);
- ok(SUCCEEDED(hr), "IDirectDraw_GetCaps failed, hr %#x.\n", hr);
You are never reading ddcaps. I suspect it is a leftover from the now-removed out of (video)memory tests.
surfacedesc.dwFlags = tests[i].flags | DDSD_PIXELFORMAT;
You are already setting DDSD_PIXELFORMAT in all of tests[i].flags, there's no need to set it twice. Remove one of them, preferably the one in tests[].flags. You can move DDSD_CAPS as well. Henri mentioned the same issue in his feedback.
The rest are some minor style issues, but please fix them as well:
- DWORD i,j;
I'd prefer unsigned int i, j, but that's not a strong opinion.
todo_wine ok(hr == tests[i].hr || broken(hr == DDERR_INVALIDPARAMS), "Pixelformat %s, test %d returned %08x\n", formats[j].name, i, hr);
i is unsigned, print it with %u.
- hr = IDirectDraw_CreateSurface(ddraw, &surfacedesc, &surface, NULL);
- ok(SUCCEEDED(hr), "CreateSurface returned %08x\n", hr);
- hr = IDirectDrawSurface_GetSurfaceDesc(surface, &surfacedesc);
- ok(SUCCEEDED(hr), "GetSurfaceDesc returned %x\n", hr);
Please be consistent with the format you use. Tests added in recent years use %#x, I recommend to use this.