ddraw/tests: Introduce a helper function to create windows.
Mostly for consistency with other D3D tests. Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
449308ec5d
commit
a86af72270
|
@ -157,14 +157,23 @@ static IDirectDrawSurface *create_overlay(IDirectDraw *ddraw,
|
||||||
return surface;
|
return surface;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static HWND create_window(void)
|
||||||
|
{
|
||||||
|
RECT r = {0, 0, 640, 480};
|
||||||
|
|
||||||
|
AdjustWindowRect(&r, WS_OVERLAPPEDWINDOW | WS_VISIBLE, FALSE);
|
||||||
|
|
||||||
|
return CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE,
|
||||||
|
CW_USEDEFAULT, CW_USEDEFAULT, r.right - r.left, r.bottom - r.top, NULL, NULL, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
static DWORD WINAPI create_window_thread_proc(void *param)
|
static DWORD WINAPI create_window_thread_proc(void *param)
|
||||||
{
|
{
|
||||||
struct create_window_thread_param *p = param;
|
struct create_window_thread_param *p = param;
|
||||||
DWORD res;
|
DWORD res;
|
||||||
BOOL ret;
|
BOOL ret;
|
||||||
|
|
||||||
p->window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
p->window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ret = SetEvent(p->window_created);
|
ret = SetEvent(p->window_created);
|
||||||
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
||||||
|
|
||||||
|
@ -667,8 +676,7 @@ static void test_coop_level_create_device_window(void)
|
||||||
IDirectDraw *ddraw;
|
IDirectDraw *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
focus_window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
focus_window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -971,8 +979,7 @@ static void test_coop_level_d3d_state(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1044,8 +1051,7 @@ static void test_surface_interface_mismatch(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1161,8 +1167,7 @@ static void test_viewport(void)
|
||||||
IDirect3DDevice *device;
|
IDirect3DDevice *device;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1288,8 +1293,7 @@ static void test_zenable(void)
|
||||||
UINT i, j;
|
UINT i, j;
|
||||||
void *ptr;
|
void *ptr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1426,8 +1430,7 @@ static void test_ck_rgba(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
UINT i;
|
UINT i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1585,8 +1588,7 @@ static void test_ck_default(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
void *ptr;
|
void *ptr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1742,8 +1744,7 @@ static void test_ck_complex(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
if (!(device = create_device(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
||||||
|
@ -1967,8 +1968,7 @@ static void test_surface_qi(void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
/* Try to create a D3D device to see if the ddraw implementation supports
|
/* Try to create a D3D device to see if the ddraw implementation supports
|
||||||
|
@ -2054,8 +2054,7 @@ static void test_device_qi(void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -3315,10 +3314,8 @@ static void test_coop_level_multi_window(void)
|
||||||
IDirectDraw *ddraw;
|
IDirectDraw *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window1 = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window1 = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
window2 = create_window();
|
||||||
window2 = CreateWindowA("static", "ddraw_test2", WS_OVERLAPPEDWINDOW,
|
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -3346,8 +3343,7 @@ static void test_clear_rect_count(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -3579,8 +3575,7 @@ static void test_unsupported_formats(void)
|
||||||
};
|
};
|
||||||
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -3816,8 +3811,7 @@ static void test_rt_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4015,8 +4009,7 @@ static void test_primary_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -4101,8 +4094,7 @@ static void test_surface_lock(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4182,8 +4174,7 @@ static void test_surface_discard(void)
|
||||||
};
|
};
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4304,8 +4295,7 @@ static void test_flip(void)
|
||||||
{"TEXTURE", DDSCAPS_TEXTURE},
|
{"TEXTURE", DDSCAPS_TEXTURE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -4524,8 +4514,7 @@ static void test_sysmem_overlay(void)
|
||||||
IDirectDrawSurface *surface;
|
IDirectDrawSurface *surface;
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -4565,8 +4554,7 @@ static void test_primary_palette(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw_SetDisplayMode(ddraw, 640, 480, 8)))
|
if (FAILED(IDirectDraw_SetDisplayMode(ddraw, 640, 480, 8)))
|
||||||
|
@ -4730,8 +4718,7 @@ static void test_surface_attachment(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5183,8 +5170,7 @@ static void test_create_surface_pitch(void)
|
||||||
};
|
};
|
||||||
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5282,8 +5268,7 @@ static void test_mipmap(void)
|
||||||
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 6},
|
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 6},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5369,8 +5354,7 @@ static void test_palette_complex(void)
|
||||||
RGBQUAD rgbquad;
|
RGBQUAD rgbquad;
|
||||||
UINT count;
|
UINT count;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5494,8 +5478,7 @@ static void test_p8_blit(void)
|
||||||
};
|
};
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5653,8 +5636,7 @@ static void test_material(void)
|
||||||
};
|
};
|
||||||
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -5888,8 +5870,7 @@ static void test_lighting(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -6140,8 +6121,7 @@ static void test_palette_gdi(void)
|
||||||
RGBQUAD rgbquad[255];
|
RGBQUAD rgbquad[255];
|
||||||
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6444,8 +6424,7 @@ static void test_palette_alpha(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw_SetDisplayMode(ddraw, 640, 480, 8)))
|
if (FAILED(IDirectDraw_SetDisplayMode(ddraw, 640, 480, 8)))
|
||||||
|
@ -6736,8 +6715,7 @@ static void test_surface_desc_lock(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6829,8 +6807,7 @@ static void test_texturemapblend(void)
|
||||||
{{640.0f}, {480.0f}, {0.0f}, {1.0f}, {0x008000ff}, {0}, {1.0f}, {1.0f}},
|
{{640.0f}, {480.0f}, {0.0f}, {1.0f}, {0x008000ff}, {0}, {1.0f}, {1.0f}},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -7220,8 +7197,7 @@ static void test_viewport_clear_rect(void)
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -7436,8 +7412,7 @@ static void test_color_fill(void)
|
||||||
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
is_warp = ddraw_is_warp(ddraw);
|
is_warp = ddraw_is_warp(ddraw);
|
||||||
|
@ -7860,8 +7835,7 @@ static void test_colorkey_precision(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -8132,8 +8106,7 @@ static void test_range_colorkey(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8285,8 +8258,7 @@ static void test_shademode(void)
|
||||||
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -8421,8 +8393,7 @@ static void test_lockrect_invalid(void)
|
||||||
{DDSCAPS_TEXTURE | DDSCAPS_VIDEOMEMORY, "vidmem texture", DDERR_INVALIDPARAMS},
|
{DDSCAPS_TEXTURE | DDSCAPS_VIDEOMEMORY, "vidmem texture", DDERR_INVALIDPARAMS},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8533,8 +8504,7 @@ static void test_yv12_overlay(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8656,8 +8626,7 @@ static void test_offscreen_overlay(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8736,8 +8705,7 @@ static void test_overlay_rect(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8857,8 +8825,7 @@ static void test_blt(void)
|
||||||
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -8970,8 +8937,7 @@ static void test_getdc(void)
|
||||||
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9351,8 +9317,7 @@ static void test_transform_vertices(void)
|
||||||
out[i].unused4 = 0xcafecafe;
|
out[i].unused4 = 0xcafecafe;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -10092,8 +10057,7 @@ static void test_texture_load(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
void *ptr;
|
void *ptr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -10227,8 +10191,7 @@ static void test_ck_operation(void)
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
|
|
@ -159,14 +159,23 @@ static IDirectDrawSurface *create_overlay(IDirectDraw2 *ddraw,
|
||||||
return surface;
|
return surface;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static HWND create_window(void)
|
||||||
|
{
|
||||||
|
RECT r = {0, 0, 640, 480};
|
||||||
|
|
||||||
|
AdjustWindowRect(&r, WS_OVERLAPPEDWINDOW | WS_VISIBLE, FALSE);
|
||||||
|
|
||||||
|
return CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE,
|
||||||
|
CW_USEDEFAULT, CW_USEDEFAULT, r.right - r.left, r.bottom - r.top, NULL, NULL, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
static DWORD WINAPI create_window_thread_proc(void *param)
|
static DWORD WINAPI create_window_thread_proc(void *param)
|
||||||
{
|
{
|
||||||
struct create_window_thread_param *p = param;
|
struct create_window_thread_param *p = param;
|
||||||
DWORD res;
|
DWORD res;
|
||||||
BOOL ret;
|
BOOL ret;
|
||||||
|
|
||||||
p->window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
p->window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ret = SetEvent(p->window_created);
|
ret = SetEvent(p->window_created);
|
||||||
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
||||||
|
|
||||||
|
@ -562,8 +571,7 @@ static void test_coop_level_create_device_window(void)
|
||||||
IDirectDraw2 *ddraw;
|
IDirectDraw2 *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
focus_window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
focus_window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -867,8 +875,7 @@ static void test_coop_level_d3d_state(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -955,8 +962,7 @@ static void test_surface_interface_mismatch(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1090,8 +1096,7 @@ static void test_depth_blit(void)
|
||||||
D3DRECT d3drect;
|
D3DRECT d3drect;
|
||||||
IDirect3DMaterial2 *background;
|
IDirect3DMaterial2 *background;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1349,8 +1354,7 @@ static void test_viewport(void)
|
||||||
IDirect3DDevice2 *device;
|
IDirect3DDevice2 *device;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1537,8 +1541,7 @@ static void test_zenable(void)
|
||||||
UINT x, y;
|
UINT x, y;
|
||||||
UINT i, j;
|
UINT i, j;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1640,8 +1643,7 @@ static void test_ck_rgba(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
UINT i;
|
UINT i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1772,8 +1774,7 @@ static void test_ck_default(void)
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -1877,8 +1878,7 @@ static void test_ck_complex(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
if (!(device = create_device(ddraw, window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
||||||
|
@ -2102,8 +2102,7 @@ static void test_surface_qi(void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
/* Try to create a D3D device to see if the ddraw implementation supports
|
/* Try to create a D3D device to see if the ddraw implementation supports
|
||||||
|
@ -2188,8 +2187,7 @@ static void test_device_qi(void)
|
||||||
IDirectDraw2 *ddraw;
|
IDirectDraw2 *ddraw;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -3536,10 +3534,8 @@ static void test_coop_level_multi_window(void)
|
||||||
IDirectDraw2 *ddraw;
|
IDirectDraw2 *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window1 = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window1 = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
window2 = create_window();
|
||||||
window2 = CreateWindowA("static", "ddraw_test2", WS_OVERLAPPEDWINDOW,
|
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -3567,8 +3563,7 @@ static void test_clear_rect_count(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -3656,9 +3651,7 @@ static void test_coop_level_versions(void)
|
||||||
IDirectDraw2 *ddraw2;
|
IDirectDraw2 *ddraw2;
|
||||||
DDSURFACEDESC ddsd;
|
DDSURFACEDESC ddsd;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
ddraw2 = create_ddraw();
|
ddraw2 = create_ddraw();
|
||||||
ok(!!ddraw2, "Failed to create a ddraw object.\n");
|
ok(!!ddraw2, "Failed to create a ddraw object.\n");
|
||||||
/* Newly created ddraw objects restore the mode on ddraw2+::SetCooperativeLevel(NORMAL) */
|
/* Newly created ddraw objects restore the mode on ddraw2+::SetCooperativeLevel(NORMAL) */
|
||||||
|
@ -3832,8 +3825,7 @@ static void test_lighting_interface_versions(void)
|
||||||
{ D3DVT_TLVERTEX, tlquad, TRUE, TRUE, D3DDP_DONOTLIGHT, 0x008080ff},
|
{ D3DVT_TLVERTEX, tlquad, TRUE, TRUE, D3DDP_DONOTLIGHT, 0x008080ff},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4084,8 +4076,7 @@ static void test_unsupported_formats(void)
|
||||||
};
|
};
|
||||||
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4364,8 +4355,7 @@ static void test_rt_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4628,8 +4618,7 @@ static void test_primary_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -4714,8 +4703,7 @@ static void test_surface_lock(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4795,8 +4783,7 @@ static void test_surface_discard(void)
|
||||||
};
|
};
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -4917,8 +4904,7 @@ static void test_flip(void)
|
||||||
{"TEXTURE", DDSCAPS_TEXTURE},
|
{"TEXTURE", DDSCAPS_TEXTURE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -5158,8 +5144,7 @@ static void test_set_surface_desc(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE | DDSCAPS_SYSTEMMEMORY, FALSE, "systemmemory primary"},
|
{DDSCAPS_PRIMARYSURFACE | DDSCAPS_SYSTEMMEMORY, FALSE, "systemmemory primary"},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5455,8 +5440,7 @@ static void test_user_memory_getdc(void)
|
||||||
HDC dc;
|
HDC dc;
|
||||||
unsigned int x, y;
|
unsigned int x, y;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -5555,8 +5539,7 @@ static void test_sysmem_overlay(void)
|
||||||
IDirectDrawSurface *surface;
|
IDirectDrawSurface *surface;
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -5595,8 +5578,7 @@ static void test_primary_palette(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw2_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
if (FAILED(IDirectDraw2_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
||||||
|
@ -5760,8 +5742,7 @@ static void test_surface_attachment(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6213,8 +6194,7 @@ static void test_create_surface_pitch(void)
|
||||||
};
|
};
|
||||||
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6314,8 +6294,7 @@ static void test_mipmap(void)
|
||||||
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 6},
|
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 6},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6406,8 +6385,7 @@ static void test_palette_complex(void)
|
||||||
RGBQUAD rgbquad;
|
RGBQUAD rgbquad;
|
||||||
UINT count;
|
UINT count;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6534,8 +6512,7 @@ static void test_p8_blit(void)
|
||||||
};
|
};
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6689,8 +6666,7 @@ static void test_material(void)
|
||||||
};
|
};
|
||||||
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -6907,8 +6883,7 @@ static void test_lighting(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -7202,8 +7177,7 @@ static void test_specular_lighting(void)
|
||||||
D3DVERTEX *quad;
|
D3DVERTEX *quad;
|
||||||
WORD *indices;
|
WORD *indices;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -7366,8 +7340,7 @@ static void test_palette_gdi(void)
|
||||||
RGBQUAD rgbquad[255];
|
RGBQUAD rgbquad[255];
|
||||||
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7671,8 +7644,7 @@ static void test_palette_alpha(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw2_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
if (FAILED(IDirectDraw2_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
||||||
|
@ -7970,8 +7942,7 @@ static void test_surface_desc_lock(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8059,8 +8030,7 @@ static void test_texturemapblend(void)
|
||||||
{{640.0f}, {480.0f}, {0.0f}, {1.0f}, {0x008000ff}, {0}, {1.0f}, {1.0f}},
|
{{640.0f}, {480.0f}, {0.0f}, {1.0f}, {0x008000ff}, {0}, {1.0f}, {1.0f}},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -8362,8 +8332,7 @@ static void test_viewport_clear_rect(void)
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -8578,8 +8547,7 @@ static void test_color_fill(void)
|
||||||
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
is_warp = ddraw_is_warp(ddraw);
|
is_warp = ddraw_is_warp(ddraw);
|
||||||
|
@ -8998,8 +8966,7 @@ static void test_colorkey_precision(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -9247,8 +9214,7 @@ static void test_range_colorkey(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9400,8 +9366,7 @@ static void test_shademode(void)
|
||||||
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -9513,8 +9478,7 @@ static void test_lockrect_invalid(void)
|
||||||
{DDSCAPS_TEXTURE | DDSCAPS_VIDEOMEMORY, "vidmem texture", DDERR_INVALIDPARAMS},
|
{DDSCAPS_TEXTURE | DDSCAPS_VIDEOMEMORY, "vidmem texture", DDERR_INVALIDPARAMS},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9628,8 +9592,7 @@ static void test_yv12_overlay(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9751,8 +9714,7 @@ static void test_offscreen_overlay(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9831,8 +9793,7 @@ static void test_overlay_rect(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9952,8 +9913,7 @@ static void test_blt(void)
|
||||||
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -10065,8 +10025,7 @@ static void test_getdc(void)
|
||||||
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -10361,8 +10320,7 @@ static void test_draw_primitive(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -10442,8 +10400,7 @@ static void test_edge_antialiasing_blending(void)
|
||||||
{{ 1.0f}, { 1.0f}, {0.1f}, 0, {0xccff0000}},
|
{{ 1.0f}, { 1.0f}, {0.1f}, 0, {0xccff0000}},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -10727,8 +10684,7 @@ static void test_transform_vertices(void)
|
||||||
out[i].unused4 = 0xcafecafe;
|
out[i].unused4 = 0xcafecafe;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
if (!(device = create_device(ddraw, window, DDSCL_NORMAL)))
|
||||||
|
@ -11552,8 +11508,7 @@ static void test_ck_operation(void)
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw2_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
|
|
@ -157,14 +157,23 @@ static IDirectDrawSurface4 *create_overlay(IDirectDraw4 *ddraw,
|
||||||
return surface;
|
return surface;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static HWND create_window(void)
|
||||||
|
{
|
||||||
|
RECT r = {0, 0, 640, 480};
|
||||||
|
|
||||||
|
AdjustWindowRect(&r, WS_OVERLAPPEDWINDOW | WS_VISIBLE, FALSE);
|
||||||
|
|
||||||
|
return CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE,
|
||||||
|
CW_USEDEFAULT, CW_USEDEFAULT, r.right - r.left, r.bottom - r.top, NULL, NULL, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
static DWORD WINAPI create_window_thread_proc(void *param)
|
static DWORD WINAPI create_window_thread_proc(void *param)
|
||||||
{
|
{
|
||||||
struct create_window_thread_param *p = param;
|
struct create_window_thread_param *p = param;
|
||||||
DWORD res;
|
DWORD res;
|
||||||
BOOL ret;
|
BOOL ret;
|
||||||
|
|
||||||
p->window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
p->window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ret = SetEvent(p->window_created);
|
ret = SetEvent(p->window_created);
|
||||||
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
||||||
|
|
||||||
|
@ -554,8 +563,7 @@ static void test_process_vertices(void)
|
||||||
6.0f, 7.0f, 8.0f, 1.0f,
|
6.0f, 7.0f, 8.0f, 1.0f,
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "d3d7_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -737,8 +745,7 @@ static void test_coop_level_create_device_window(void)
|
||||||
IDirectDraw4 *ddraw;
|
IDirectDraw4 *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
focus_window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
focus_window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -1041,8 +1048,7 @@ static void test_coop_level_d3d_state(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1117,8 +1123,7 @@ static void test_surface_interface_mismatch(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -1248,8 +1253,7 @@ static void test_depth_blit(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
D3DRECT d3drect;
|
D3DRECT d3drect;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1500,8 +1504,7 @@ static void test_viewport(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
IDirect3DDevice3 *device;
|
IDirect3DDevice3 *device;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1683,8 +1686,7 @@ static void test_zenable(void)
|
||||||
UINT x, y;
|
UINT x, y;
|
||||||
UINT i, j;
|
UINT i, j;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1783,8 +1785,7 @@ static void test_ck_rgba(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
UINT i;
|
UINT i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1916,9 +1917,7 @@ static void test_ck_default(void)
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -2019,8 +2018,7 @@ static void test_ck_complex(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
if (!(device = create_device(window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -2246,8 +2244,7 @@ static void test_surface_qi(void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
/* Try to create a D3D device to see if the ddraw implementation supports
|
/* Try to create a D3D device to see if the ddraw implementation supports
|
||||||
* D3D. 64-bit ddraw in particular doesn't seem to support D3D, and
|
* D3D. 64-bit ddraw in particular doesn't seem to support D3D, and
|
||||||
* doesn't support e.g. the IDirect3DTexture interfaces. */
|
* doesn't support e.g. the IDirect3DTexture interfaces. */
|
||||||
|
@ -2332,8 +2329,7 @@ static void test_device_qi(void)
|
||||||
IDirect3DDevice3 *device;
|
IDirect3DDevice3 *device;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3675,9 +3671,7 @@ static void test_vb_discard(void)
|
||||||
static const unsigned int vbsize = 16;
|
static const unsigned int vbsize = 16;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3740,10 +3734,8 @@ static void test_coop_level_multi_window(void)
|
||||||
IDirectDraw4 *ddraw;
|
IDirectDraw4 *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window1 = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window1 = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
window2 = create_window();
|
||||||
window2 = CreateWindowA("static", "ddraw_test2", WS_OVERLAPPEDWINDOW,
|
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -3786,9 +3778,7 @@ static void test_draw_strided(void)
|
||||||
IDirect3DViewport3 *viewport;
|
IDirect3DViewport3 *viewport;
|
||||||
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3951,8 +3941,7 @@ static void test_lighting(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4251,8 +4240,7 @@ static void test_specular_lighting(void)
|
||||||
} *quad;
|
} *quad;
|
||||||
WORD *indices;
|
WORD *indices;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4380,8 +4368,7 @@ static void test_clear_rect_count(void)
|
||||||
IDirect3DViewport3 *viewport;
|
IDirect3DViewport3 *viewport;
|
||||||
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4451,9 +4438,7 @@ static void test_coop_level_versions(void)
|
||||||
IDirectDraw4 *ddraw4;
|
IDirectDraw4 *ddraw4;
|
||||||
DDSURFACEDESC ddsd;
|
DDSURFACEDESC ddsd;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
ddraw4 = create_ddraw();
|
ddraw4 = create_ddraw();
|
||||||
ok(!!ddraw4, "Failed to create a ddraw object.\n");
|
ok(!!ddraw4, "Failed to create a ddraw object.\n");
|
||||||
/* Newly created ddraw objects restore the mode on ddraw2+::SetCooperativeLevel(NORMAL) */
|
/* Newly created ddraw objects restore the mode on ddraw2+::SetCooperativeLevel(NORMAL) */
|
||||||
|
@ -4689,9 +4674,7 @@ static void test_lighting_interface_versions(void)
|
||||||
{ D3DFVF_TLVERTEX, tlquad, TRUE, TRUE, D3DDP_DONOTLIGHT, 0x008080ff},
|
{ D3DFVF_TLVERTEX, tlquad, TRUE, TRUE, D3DDP_DONOTLIGHT, 0x008080ff},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -5125,9 +5108,7 @@ static void test_block_formats_creation(void)
|
||||||
{DDSD_LPSURFACE | DDSD_PITCH | DDSD_LINEARSIZE, SIZE_TYPE_SIZE, 0, DD_OK},
|
{DDSD_LPSURFACE | DDSD_PITCH | DDSD_LINEARSIZE, SIZE_TYPE_SIZE, 0, DD_OK},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -5351,9 +5332,7 @@ static void test_unsupported_formats(void)
|
||||||
};
|
};
|
||||||
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -5612,8 +5591,7 @@ static void test_rt_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5856,8 +5834,7 @@ static void test_primary_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -5975,8 +5952,7 @@ static void test_surface_lock(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6071,9 +6047,7 @@ static void test_surface_discard(void)
|
||||||
};
|
};
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -6192,8 +6166,7 @@ static void test_flip(void)
|
||||||
{"TEXTURE", DDSCAPS_TEXTURE},
|
{"TEXTURE", DDSCAPS_TEXTURE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -6434,8 +6407,7 @@ static void test_set_surface_desc(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE | DDSCAPS_SYSTEMMEMORY, 0, FALSE, "systemmemory primary"},
|
{DDSCAPS_PRIMARYSURFACE | DDSCAPS_SYSTEMMEMORY, 0, FALSE, "systemmemory primary"},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6727,8 +6699,7 @@ static void test_user_memory_getdc(void)
|
||||||
HDC dc;
|
HDC dc;
|
||||||
unsigned int x, y;
|
unsigned int x, y;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -6823,8 +6794,7 @@ static void test_sysmem_overlay(void)
|
||||||
IDirectDrawSurface4 *surface;
|
IDirectDrawSurface4 *surface;
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -6863,8 +6833,7 @@ static void test_primary_palette(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw4_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
if (FAILED(IDirectDraw4_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
||||||
|
@ -7029,8 +6998,7 @@ static void test_surface_attachment(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7303,8 +7271,7 @@ static void test_private_data(void)
|
||||||
{0x9b,0x4b,0x89,0xd7,0xd1,0x12,0xe7,0x2b}
|
{0x9b,0x4b,0x89,0xd7,0xd1,0x12,0xe7,0x2b}
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7704,8 +7671,7 @@ static void test_create_surface_pitch(void)
|
||||||
};
|
};
|
||||||
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7804,8 +7770,7 @@ static void test_mipmap(void)
|
||||||
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 6},
|
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 6},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7891,8 +7856,7 @@ static void test_palette_complex(void)
|
||||||
RGBQUAD rgbquad;
|
RGBQUAD rgbquad;
|
||||||
UINT count;
|
UINT count;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8016,8 +7980,7 @@ static void test_p8_blit(void)
|
||||||
};
|
};
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8186,8 +8149,7 @@ static void test_material(void)
|
||||||
};
|
};
|
||||||
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
static D3DRECT clear_rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -8326,8 +8288,7 @@ static void test_palette_gdi(void)
|
||||||
RGBQUAD rgbquad[255];
|
RGBQUAD rgbquad[255];
|
||||||
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8630,8 +8591,7 @@ static void test_palette_alpha(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw4_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
if (FAILED(IDirectDraw4_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
||||||
|
@ -8775,9 +8735,7 @@ static void test_vb_writeonly(void)
|
||||||
{640.0f, 0.0f, 0.0f, 1.0f},
|
{640.0f, 0.0f, 0.0f, 1.0f},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9019,8 +8977,7 @@ static void test_surface_desc_lock(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9160,9 +9117,7 @@ static void test_signed_formats(void)
|
||||||
unsigned int i, width, x, y;
|
unsigned int i, width, x, y;
|
||||||
D3DDEVICEDESC device_desc, hel_desc;
|
D3DDEVICEDESC device_desc, hel_desc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9473,9 +9428,7 @@ static void test_color_fill(void)
|
||||||
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9864,8 +9817,7 @@ static void test_texcoordindex(void)
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
DWORD *ptr;
|
DWORD *ptr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10092,8 +10044,7 @@ static void test_colorkey_precision(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10347,8 +10298,7 @@ static void test_range_colorkey(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -10506,9 +10456,7 @@ static void test_shademode(void)
|
||||||
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10640,8 +10588,7 @@ static void test_lockrect_invalid(void)
|
||||||
{DDSCAPS_TEXTURE, DDSCAPS2_TEXTUREMANAGE, "managed texture", DDERR_INVALIDPARAMS},
|
{DDSCAPS_TEXTURE, DDSCAPS2_TEXTUREMANAGE, "managed texture", DDERR_INVALIDPARAMS},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -10754,8 +10701,7 @@ static void test_yv12_overlay(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -10877,8 +10823,7 @@ static void test_offscreen_overlay(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -10957,8 +10902,7 @@ static void test_overlay_rect(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11079,8 +11023,7 @@ static void test_blt(void)
|
||||||
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -11155,9 +11098,7 @@ static void test_color_clamping(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -11292,8 +11233,7 @@ static void test_getdc(void)
|
||||||
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11593,9 +11533,7 @@ static void test_draw_primitive(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
void *data;
|
void *data;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -11726,8 +11664,7 @@ static void test_edge_antialiasing_blending(void)
|
||||||
{{ 1.0f, 1.0f, 0.1f}, 0xccff0000},
|
{{ 1.0f, 1.0f, 0.1f}, 0xccff0000},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device.\n");
|
skip("Failed to create a 3D device.\n");
|
||||||
|
@ -12019,8 +11956,7 @@ static void test_transform_vertices(void)
|
||||||
out[i].unused4 = 0xcafecafe;
|
out[i].unused4 = 0xcafecafe;
|
||||||
}
|
}
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device.\n");
|
skip("Failed to create a 3D device.\n");
|
||||||
|
@ -12827,8 +12763,7 @@ static void test_get_surface_from_dc(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
DWORD ret;
|
DWORD ret;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -12940,8 +12875,7 @@ static void test_ck_operation(void)
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw4_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -13407,8 +13341,7 @@ static void test_vb_refcount(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "d3d3_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -13522,8 +13455,7 @@ static void test_compute_sphere_visibility(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "d3d_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
|
|
@ -167,14 +167,23 @@ static IDirectDrawSurface7 *create_overlay(IDirectDraw7 *ddraw,
|
||||||
return surface;
|
return surface;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static HWND create_window(void)
|
||||||
|
{
|
||||||
|
RECT r = {0, 0, 640, 480};
|
||||||
|
|
||||||
|
AdjustWindowRect(&r, WS_OVERLAPPEDWINDOW | WS_VISIBLE, FALSE);
|
||||||
|
|
||||||
|
return CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW | WS_VISIBLE,
|
||||||
|
CW_USEDEFAULT, CW_USEDEFAULT, r.right - r.left, r.bottom - r.top, NULL, NULL, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
static DWORD WINAPI create_window_thread_proc(void *param)
|
static DWORD WINAPI create_window_thread_proc(void *param)
|
||||||
{
|
{
|
||||||
struct create_window_thread_param *p = param;
|
struct create_window_thread_param *p = param;
|
||||||
DWORD res;
|
DWORD res;
|
||||||
BOOL ret;
|
BOOL ret;
|
||||||
|
|
||||||
p->window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
p->window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ret = SetEvent(p->window_created);
|
ret = SetEvent(p->window_created);
|
||||||
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
ok(ret, "SetEvent failed, last error %#x.\n", GetLastError());
|
||||||
|
|
||||||
|
@ -473,8 +482,7 @@ static void test_process_vertices(void)
|
||||||
1.0f, 0.0f, 0.0f, 1.0f,
|
1.0f, 0.0f, 0.0f, 1.0f,
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "d3d7_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -640,8 +648,7 @@ static void test_coop_level_create_device_window(void)
|
||||||
IDirectDraw7 *ddraw;
|
IDirectDraw7 *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
focus_window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
focus_window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -942,8 +949,7 @@ static void test_coop_level_d3d_state(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1013,8 +1019,7 @@ static void test_surface_interface_mismatch(void)
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -1138,8 +1143,7 @@ static void test_depth_blit(void)
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1285,8 +1289,7 @@ static void test_texture_load_ckey(void)
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
IDirect3D7 *d3d;
|
IDirect3D7 *d3d;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1383,8 +1386,7 @@ static void test_zenable(void)
|
||||||
UINT x, y;
|
UINT x, y;
|
||||||
UINT i, j;
|
UINT i, j;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1475,8 +1477,7 @@ static void test_ck_rgba(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
UINT i;
|
UINT i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1596,9 +1597,7 @@ static void test_ck_default(void)
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1692,8 +1691,7 @@ static void test_ck_complex(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
if (!(device = create_device(window, DDSCL_EXCLUSIVE | DDSCL_FULLSCREEN)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -1973,8 +1971,7 @@ static void test_surface_qi(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
/* Try to create a D3D device to see if the ddraw implementation supports
|
/* Try to create a D3D device to see if the ddraw implementation supports
|
||||||
* D3D. 64-bit ddraw in particular doesn't seem to support D3D, and
|
* D3D. 64-bit ddraw in particular doesn't seem to support D3D, and
|
||||||
* doesn't support e.g. the IDirect3DTexture interfaces. */
|
* doesn't support e.g. the IDirect3DTexture interfaces. */
|
||||||
|
@ -2059,8 +2056,7 @@ static void test_device_qi(void)
|
||||||
IDirect3DDevice7 *device;
|
IDirect3DDevice7 *device;
|
||||||
HWND window;
|
HWND window;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3401,9 +3397,7 @@ static void test_vb_discard(void)
|
||||||
static const unsigned int vbsize = 16;
|
static const unsigned int vbsize = 16;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3466,10 +3460,8 @@ static void test_coop_level_multi_window(void)
|
||||||
IDirectDraw7 *ddraw;
|
IDirectDraw7 *ddraw;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window1 = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window1 = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
window2 = create_window();
|
||||||
window2 = CreateWindowA("static", "ddraw_test2", WS_OVERLAPPEDWINDOW,
|
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -3510,9 +3502,7 @@ static void test_draw_strided(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
D3DDRAWPRIMITIVESTRIDEDDATA strided;
|
D3DDRAWPRIMITIVESTRIDEDDATA strided;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3666,8 +3656,7 @@ static void test_lighting(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -3958,8 +3947,7 @@ static void test_specular_lighting(void)
|
||||||
} *quad;
|
} *quad;
|
||||||
WORD *indices;
|
WORD *indices;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4073,8 +4061,7 @@ static void test_clear_rect_count(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
D3DRECT rect = {{0}, {0}, {640}, {480}};
|
D3DRECT rect = {{0}, {0}, {640}, {480}};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4145,9 +4132,7 @@ static void test_coop_level_versions(void)
|
||||||
IDirectDraw7 *ddraw7;
|
IDirectDraw7 *ddraw7;
|
||||||
DDSURFACEDESC ddsd;
|
DDSURFACEDESC ddsd;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test1", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
ddraw7 = create_ddraw();
|
ddraw7 = create_ddraw();
|
||||||
ok(!!ddraw7, "Failed to create a ddraw object.\n");
|
ok(!!ddraw7, "Failed to create a ddraw object.\n");
|
||||||
/* Newly created ddraw objects restore the mode on ddraw2+::SetCooperativeLevel(NORMAL) */
|
/* Newly created ddraw objects restore the mode on ddraw2+::SetCooperativeLevel(NORMAL) */
|
||||||
|
@ -4280,9 +4265,7 @@ static void test_fog_special(void)
|
||||||
IDirect3DDevice7 *device;
|
IDirect3DDevice7 *device;
|
||||||
IDirectDrawSurface7 *rt;
|
IDirectDrawSurface7 *rt;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4475,9 +4458,7 @@ static void test_lighting_interface_versions(void)
|
||||||
{ D3DFVF_TLVERTEX, tlquad, TRUE, TRUE, D3DDP_DONOTLIGHT, 0x008080ff},
|
{ D3DFVF_TLVERTEX, tlquad, TRUE, TRUE, D3DDP_DONOTLIGHT, 0x008080ff},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -4916,9 +4897,7 @@ static void test_block_formats_creation(void)
|
||||||
{DDSD_LPSURFACE | DDSD_PITCH | DDSD_LINEARSIZE, SIZE_TYPE_SIZE, 0, DDERR_INVALIDPARAMS},
|
{DDSD_LPSURFACE | DDSD_PITCH | DDSD_LINEARSIZE, SIZE_TYPE_SIZE, 0, DDERR_INVALIDPARAMS},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -5142,9 +5121,7 @@ static void test_unsupported_formats(void)
|
||||||
};
|
};
|
||||||
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
static const DWORD caps[] = {0, DDSCAPS_SYSTEMMEMORY, DDSCAPS_VIDEOMEMORY};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -5405,8 +5382,7 @@ static void test_rt_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5654,8 +5630,7 @@ static void test_primary_caps(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -5813,8 +5788,7 @@ static void test_surface_lock(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -5945,9 +5919,7 @@ static void test_surface_discard(void)
|
||||||
};
|
};
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -6068,8 +6040,7 @@ static void test_flip(void)
|
||||||
{"TEXTURE", DDSCAPS_TEXTURE},
|
{"TEXTURE", DDSCAPS_TEXTURE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
|
|
||||||
|
@ -6360,8 +6331,7 @@ static void test_set_surface_desc(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE | DDSCAPS_SYSTEMMEMORY, 0, FALSE, "systemmemory primary"},
|
{DDSCAPS_PRIMARYSURFACE | DDSCAPS_SYSTEMMEMORY, 0, FALSE, "systemmemory primary"},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6652,8 +6622,7 @@ static void test_user_memory_getdc(void)
|
||||||
HDC dc;
|
HDC dc;
|
||||||
unsigned int x, y;
|
unsigned int x, y;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6747,8 +6716,7 @@ static void test_sysmem_overlay(void)
|
||||||
IDirectDrawSurface7 *surface;
|
IDirectDrawSurface7 *surface;
|
||||||
ULONG ref;
|
ULONG ref;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -6786,8 +6754,7 @@ static void test_primary_palette(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw7_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
if (FAILED(IDirectDraw7_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
||||||
|
@ -6952,8 +6919,7 @@ static void test_surface_attachment(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7208,8 +7174,7 @@ static void test_private_data(void)
|
||||||
{0x9b,0x4b,0x89,0xd7,0xd1,0x12,0xe7,0x2b}
|
{0x9b,0x4b,0x89,0xd7,0xd1,0x12,0xe7,0x2b}
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7610,8 +7575,7 @@ static void test_create_surface_pitch(void)
|
||||||
};
|
};
|
||||||
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
DWORD flags_mask = DDSD_PITCH | DDSD_LPSURFACE | DDSD_LINEARSIZE;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7713,8 +7677,7 @@ static void test_mipmap(void)
|
||||||
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 7},
|
{0, DDSCAPS_TEXTURE | DDSCAPS_COMPLEX | DDSCAPS_MIPMAP, 32, 64, 0, DD_OK, 7},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7798,8 +7761,7 @@ static void test_palette_complex(void)
|
||||||
PALETTEENTRY palette_entries[256];
|
PALETTEENTRY palette_entries[256];
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -7934,8 +7896,7 @@ static void test_p8_blit(void)
|
||||||
};
|
};
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8064,8 +8025,7 @@ static void test_material(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -8136,8 +8096,7 @@ static void test_palette_gdi(void)
|
||||||
RGBQUAD rgbquad[255];
|
RGBQUAD rgbquad[255];
|
||||||
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
static const RGBQUAD rgb_zero = {0, 0, 0, 0};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8440,8 +8399,7 @@ static void test_palette_alpha(void)
|
||||||
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
{DDSCAPS_PRIMARYSURFACE, 0, FALSE, "primary"}
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
if (FAILED(IDirectDraw7_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
if (FAILED(IDirectDraw7_SetDisplayMode(ddraw, 640, 480, 8, 0, 0)))
|
||||||
|
@ -8585,9 +8543,7 @@ static void test_vb_writeonly(void)
|
||||||
{640.0f, 0.0f, 0.0f, 1.0f},
|
{640.0f, 0.0f, 0.0f, 1.0f},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -8854,8 +8810,7 @@ static void test_resource_priority(void)
|
||||||
{DDSCAPS_OFFSCREENPLAIN | DDSCAPS_SYSTEMMEMORY, 0, "sysmem offscreenplain", DDERR_INVALIDOBJECT, TRUE},
|
{DDSCAPS_OFFSCREENPLAIN | DDSCAPS_SYSTEMMEMORY, 0, "sysmem offscreenplain", DDERR_INVALIDOBJECT, TRUE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -8978,8 +8933,7 @@ static void test_surface_desc_lock(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -9072,9 +9026,7 @@ static void test_fog_interpolation(void)
|
||||||
};
|
};
|
||||||
D3DDEVICEDESC7 caps;
|
D3DDEVICEDESC7 caps;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9231,9 +9183,7 @@ static void test_negative_fixedfunction_fog(void)
|
||||||
};
|
};
|
||||||
D3DDEVICEDESC7 caps;
|
D3DDEVICEDESC7 caps;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9345,9 +9295,7 @@ static void test_table_fog_zw(void)
|
||||||
};
|
};
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9506,9 +9454,7 @@ static void test_signed_formats(void)
|
||||||
unsigned int i, width, x, y;
|
unsigned int i, width, x, y;
|
||||||
D3DDEVICEDESC7 device_desc;
|
D3DDEVICEDESC7 device_desc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -9798,9 +9744,7 @@ static void test_color_fill(void)
|
||||||
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
{0xaa0029, "0xaa0029", DDERR_NORASTEROPHW} /* noop */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10193,8 +10137,7 @@ static void test_texcoordindex(void)
|
||||||
D3DCOLOR color;
|
D3DCOLOR color;
|
||||||
DWORD *ptr;
|
DWORD *ptr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10430,8 +10373,7 @@ static void test_colorkey_precision(void)
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10676,8 +10618,7 @@ static void test_range_colorkey(void)
|
||||||
ULONG refcount;
|
ULONG refcount;
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -10833,9 +10774,7 @@ static void test_shademode(void)
|
||||||
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
{D3DPT_TRIANGLELIST, D3DSHADE_GOURAUD, 0x000dca28, 0x000d45c7},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -10965,8 +10904,7 @@ static void test_lockrect_invalid(void)
|
||||||
{DDSCAPS_TEXTURE, DDSCAPS2_TEXTUREMANAGE, "managed texture", DD_OK},
|
{DDSCAPS_TEXTURE, DDSCAPS2_TEXTUREMANAGE, "managed texture", DD_OK},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11089,8 +11027,7 @@ static void test_yv12_overlay(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11212,8 +11149,7 @@ static void test_offscreen_overlay(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11292,8 +11228,7 @@ static void test_overlay_rect(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HDC dc;
|
HDC dc;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11414,8 +11349,7 @@ static void test_blt(void)
|
||||||
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
{{640, 0, 0, 480}, { 0, 0, 640, 480}, DDERR_INVALIDRECT}, /* Full surface, mirrored source. */
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -11488,9 +11422,7 @@ static void test_color_clamping(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -11620,8 +11552,7 @@ static void test_getdc(void)
|
||||||
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
{0x00000000}, {0x00000000}, {0x00000000}, {0x00000000}}, FALSE},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -11922,9 +11853,7 @@ static void test_draw_primitive(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
void *data;
|
void *data;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -12051,8 +11980,7 @@ static void test_edge_antialiasing_blending(void)
|
||||||
{{ 1.0f, 1.0f, 0.1f}, 0xccff0000},
|
{{ 1.0f, 1.0f, 0.1f}, 0xccff0000},
|
||||||
};
|
};
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, NULL, NULL, NULL, NULL);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device.\n");
|
skip("Failed to create a 3D device.\n");
|
||||||
|
@ -12500,8 +12428,7 @@ static void test_get_surface_from_dc(void)
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
DWORD ret;
|
DWORD ret;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -12613,8 +12540,7 @@ static void test_ck_operation(void)
|
||||||
DDCOLORKEY ckey;
|
DDCOLORKEY ckey;
|
||||||
DDBLTFX fx;
|
DDBLTFX fx;
|
||||||
|
|
||||||
window = CreateWindowA("static", "ddraw_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
ddraw = create_ddraw();
|
ddraw = create_ddraw();
|
||||||
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
ok(!!ddraw, "Failed to create a ddraw object.\n");
|
||||||
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
hr = IDirectDraw7_SetCooperativeLevel(ddraw, window, DDSCL_NORMAL);
|
||||||
|
@ -13080,8 +13006,7 @@ static void test_vb_refcount(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "d3d7_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
@ -13203,8 +13128,7 @@ static void test_compute_sphere_visibility(void)
|
||||||
HWND window;
|
HWND window;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
window = CreateWindowA("static", "d3d_test", WS_OVERLAPPEDWINDOW,
|
window = create_window();
|
||||||
0, 0, 640, 480, 0, 0, 0, 0);
|
|
||||||
if (!(device = create_device(window, DDSCL_NORMAL)))
|
if (!(device = create_device(window, DDSCL_NORMAL)))
|
||||||
{
|
{
|
||||||
skip("Failed to create a 3D device, skipping test.\n");
|
skip("Failed to create a 3D device, skipping test.\n");
|
||||||
|
|
Loading…
Reference in New Issue