Commit 2a3ad1d2 authored by Paul Gofman's avatar Paul Gofman Committed by Alexandre Julliard

d3dx9/tests: Factor out test_effect_preshader_clear_pbool_consts() function.

parent 7178c167
...@@ -4305,6 +4305,19 @@ got (%g, %g, %g, %g), parameter %s.\n", ...@@ -4305,6 +4305,19 @@ got (%g, %g, %g, %g), parameter %s.\n",
} }
} }
static void test_effect_preshader_clear_pbool_consts(IDirect3DDevice9 *device)
{
BOOL bval = FALSE;
unsigned int i;
HRESULT hr;
for (i = 0; i < 16; ++i)
{
hr = IDirect3DDevice9_SetPixelShaderConstantB(device, i, &bval, 1);
ok(hr == D3D_OK, "Got result %#x.\n", hr);
}
}
static void test_effect_preshader(IDirect3DDevice9 *device) static void test_effect_preshader(IDirect3DDevice9 *device)
{ {
static const D3DXVECTOR4 test_effect_preshader_fvect_p[] = static const D3DXVECTOR4 test_effect_preshader_fvect_p[] =
...@@ -4368,12 +4381,9 @@ static void test_effect_preshader(IDirect3DDevice9 *device) ...@@ -4368,12 +4381,9 @@ static void test_effect_preshader(IDirect3DDevice9 *device)
hr = IDirect3DDevice9_SetPixelShaderConstantF(device, i, &fvect_filler.x, 1); hr = IDirect3DDevice9_SetPixelShaderConstantF(device, i, &fvect_filler.x, 1);
ok(hr == D3D_OK, "Got result %#x.\n", hr); ok(hr == D3D_OK, "Got result %#x.\n", hr);
} }
bval = FALSE;
for (i = 0; i < 16; ++i) test_effect_preshader_clear_pbool_consts(device);
{
hr = IDirect3DDevice9_SetPixelShaderConstantB(device, i, &bval, 1);
ok(hr == D3D_OK, "Got result %#x.\n", hr);
}
for (i = 0; i < 16; ++i) for (i = 0; i < 16; ++i)
{ {
hr = IDirect3DDevice9_SetPixelShaderConstantI(device, i, ivect_empty, 1); hr = IDirect3DDevice9_SetPixelShaderConstantI(device, i, ivect_empty, 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment