Marcus Meissner wrote:
Hi,
I am suspecting that in IDirectDraw1 the behaviour regarding backbuffer creation might change if we have a just created frontbuffer of the same size.
(This is similar to behaviour shown by bulanci.exe of http://bugs.winehq.org/show_bug.cgi?id=9008 )
Can someone please try this on Windows please?
Ciao, Marcus
diff --git a/dlls/ddraw/tests/dsurface.c b/dlls/ddraw/tests/dsurface.c index fc7bb88..50f6986 100644 --- a/dlls/ddraw/tests/dsurface.c +++ b/dlls/ddraw/tests/dsurface.c @@ -1331,10 +1331,21 @@ static void AttachmentTest(void) /* This old ddraw version happily creates explicit front buffers */ memset(&ddsd, 0, sizeof(ddsd)); ddsd.dwSize = sizeof(ddsd);
ddsd.dwHeight = 800;
ddsd.dwWidth = 600; ddsd.dwFlags = DDSD_CAPS; ddsd.ddsCaps.dwCaps = DDSCAPS_PRIMARYSURFACE | DDSCAPS_FRONTBUFFER; hr = IDirectDraw_CreateSurface(lpDD, &ddsd, &surface1, NULL); ok(hr==DD_OK,"CreateSurface returned: %x\n",hr);
/* MARCUS: Lets try creating a backbuffer with frontbuffer live... */
memset(&ddsd, 0, sizeof(ddsd));
ddsd.dwSize = sizeof(ddsd);
ddsd.dwFlags = DDSD_CAPS;
ddsd.ddsCaps.dwCaps = DDSCAPS_BACKBUFFER;
hr = IDirectDraw_CreateSurface(lpDD, &ddsd, &surface2, NULL);
ok(hr==DDERR_INVALIDCAPS,"CreateSurface backbuffer after frontbuffer returned: %x\n",hr);
IDirectDrawSurface_Release(surface1);
/* Try a single primary and two offscreen plain surfaces */
Hi, on WinXP SP2 it fails with:
dsurface.c:1347: Test failed: CreateSurface backbuffer after frontbuffer returned: 80070057 dsurface: 1109 tests executed (0 marked as todo, 1 failure), 0 skipped.