Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
573db35b
Commit
573db35b
authored
Jul 24, 2007
by
Stefan Dösinger
Committed by
Alexandre Julliard
Aug 06, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d8: Skip tests if d3d is not supported.
parent
39a8f1b2
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
35 additions
and
17 deletions
+35
-17
device.c
dlls/d3d8/tests/device.c
+26
-12
surface.c
dlls/d3d8/tests/surface.c
+1
-1
texture.c
dlls/d3d8/tests/texture.c
+1
-1
visual.c
dlls/d3d8/tests/visual.c
+6
-2
volume.c
dlls/d3d8/tests/volume.c
+1
-1
No files found.
dlls/d3d8/tests/device.c
View file @
573db35b
...
...
@@ -136,7 +136,7 @@ static void test_mipmap_levels(void)
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
goto
cleanup
;
}
...
...
@@ -181,7 +181,7 @@ static void test_swapchain(void)
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
goto
cleanup
;
}
...
...
@@ -324,7 +324,7 @@ static void test_refcount(void)
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
goto
cleanup
;
}
IDirect3DDevice8_GetDeviceCaps
(
pDevice
,
&
caps
);
...
...
@@ -638,7 +638,7 @@ static void test_cursor(void)
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
goto
cleanup
;
}
...
...
@@ -717,7 +717,7 @@ static void test_states(void)
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
goto
cleanup
;
}
...
...
@@ -741,10 +741,12 @@ static void test_shader_versions(void)
ok
(
pD3d
!=
NULL
,
"Failed to create IDirect3D8 object
\n
"
);
if
(
pD3d
!=
NULL
)
{
hr
=
IDirect3D8_GetDeviceCaps
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
&
d3dcaps
);
ok
(
SUCCEEDED
(
hr
)
,
"Failed to get D3D8 caps (%s)
\n
"
,
DXGetErrorString8
(
hr
)
);
ok
(
SUCCEEDED
(
hr
)
||
hr
==
D3DERR_NOTAVAILABLE
,
"Failed to get D3D8 caps (%08x)
\n
"
,
hr
);
if
(
SUCCEEDED
(
hr
))
{
ok
(
d3dcaps
.
VertexShaderVersion
<=
D3DVS_VERSION
(
1
,
1
),
"Unexpected VertexShaderVersion (%#x > %#x)
\n
"
,
d3dcaps
.
VertexShaderVersion
,
D3DVS_VERSION
(
1
,
1
));
ok
(
d3dcaps
.
PixelShaderVersion
<=
D3DPS_VERSION
(
1
,
4
),
"Unexpected PixelShaderVersion (%#x > %#x)
\n
"
,
d3dcaps
.
PixelShaderVersion
,
D3DPS_VERSION
(
1
,
4
));
}
else
{
skip
(
"No Direct3D support
\n
"
);
}
IDirect3D8_Release
(
pD3d
);
}
...
...
@@ -805,8 +807,12 @@ static void test_scene(void)
hr
=
IDirect3D8_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
/* no NULLREF here */
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
hr
==
D3D_OK
,
"IDirect3D8_CreateDevice failed with %s
\n
"
,
DXGetErrorString8
(
hr
));
if
(
!
pDevice
)
goto
cleanup
;
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_INVALIDCALL
,
"IDirect3D8_CreateDevice failed with %08x
\n
"
,
hr
);
if
(
!
pDevice
)
{
skip
(
"could not create device, IDirect3D8_CreateDevice returned %08x
\n
"
,
hr
);
goto
cleanup
;
}
/* Test an EndScene without beginscene. Should return an error */
hr
=
IDirect3DDevice8_EndScene
(
pDevice
);
...
...
@@ -885,8 +891,12 @@ static void test_shader(void)
hr
=
IDirect3D8_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
/* no NULLREF here */
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
hr
==
D3D_OK
,
"IDirect3D8_CreateDevice failed with %s
\n
"
,
DXGetErrorString8
(
hr
));
if
(
!
pDevice
)
goto
cleanup
;
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_INVALIDCALL
,
"IDirect3D8_CreateDevice failed with %08x
\n
"
,
hr
);
if
(
!
pDevice
)
{
skip
(
"could not create device, IDirect3D8_CreateDevice returned %08x
\n
"
,
hr
);
goto
cleanup
;
}
IDirect3DDevice8_GetDeviceCaps
(
pDevice
,
&
caps
);
/* First create a vertex shader */
...
...
@@ -1053,8 +1063,12 @@ static void test_limits(void)
hr
=
IDirect3D8_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
/* no NULLREF here */
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
hr
==
D3D_OK
,
"IDirect3D8_CreateDevice failed with %s
\n
"
,
DXGetErrorString8
(
hr
));
if
(
!
pDevice
)
goto
cleanup
;
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_INVALIDCALL
,
"IDirect3D8_CreateDevice failed with %08x
\n
"
,
hr
);
if
(
!
pDevice
)
{
skip
(
"could not create device, IDirect3D8_CreateDevice returned %08x
\n
"
,
hr
);
goto
cleanup
;
}
hr
=
IDirect3DDevice8_CreateTexture
(
pDevice
,
16
,
16
,
1
,
0
,
D3DFMT_A8R8G8B8
,
D3DPOOL_MANAGED
,
&
pTexture
);
ok
(
hr
==
D3D_OK
,
"IDirect3DDevice8_CreateTexture failed with %s
\n
"
,
DXGetErrorString8
(
hr
));
...
...
dlls/d3d8/tests/surface.c
View file @
573db35b
...
...
@@ -59,7 +59,7 @@ static IDirect3DDevice8 *init_d3d8(HMODULE d3d8_handle)
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
return
NULL
;
}
...
...
dlls/d3d8/tests/texture.c
View file @
573db35b
...
...
@@ -59,7 +59,7 @@ static IDirect3DDevice8 *init_d3d8(HMODULE d3d8_handle)
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
return
NULL
;
}
...
...
dlls/d3d8/tests/visual.c
View file @
573db35b
...
...
@@ -120,7 +120,7 @@ static IDirect3DDevice8 *init_d3d8(void)
present_parameters
.
AutoDepthStencilFormat
=
D3DFMT_D16
;
hr
=
IDirect3D8_CreateDevice
(
d3d8_ptr
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
present_parameters
.
hDeviceWindow
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
present_parameters
,
&
device_ptr
);
ok
(
hr
==
D3D_OK
,
"IDirect3D_CreateDevice returned: %s
\n
"
,
DXGetErrorString8
(
hr
));
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_INVALIDCALL
,
"IDirect3D_CreateDevice returned: %s
\n
"
,
DXGetErrorString8
(
hr
));
return
device_ptr
;
}
...
...
@@ -625,7 +625,11 @@ START_TEST(visual)
}
device_ptr
=
init_d3d8
();
if
(
!
device_ptr
)
return
;
if
(
!
device_ptr
)
{
skip
(
"Could not initialize direct3d
\n
"
);
return
;
}
IDirect3DDevice8_GetDeviceCaps
(
device_ptr
,
&
caps
);
...
...
dlls/d3d8/tests/volume.c
View file @
573db35b
...
...
@@ -59,7 +59,7 @@ static IDirect3DDevice8 *init_d3d8(HMODULE d3d8_handle)
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D8_CreateDevice returned %#x
\n
"
,
hr
);
return
NULL
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment