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
9ae22f1a
Commit
9ae22f1a
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
d3d9: Do not fail if d3d9 is not available.
parent
573db35b
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
34 additions
and
14 deletions
+34
-14
device.c
dlls/d3d9/tests/device.c
+19
-7
query.c
dlls/d3d9/tests/query.c
+6
-2
shader.c
dlls/d3d9/tests/shader.c
+1
-1
surface.c
dlls/d3d9/tests/surface.c
+1
-1
texture.c
dlls/d3d9/tests/texture.c
+1
-1
visual.c
dlls/d3d9/tests/visual.c
+6
-2
No files found.
dlls/d3d9/tests/device.c
View file @
9ae22f1a
...
...
@@ -739,7 +739,7 @@ static void test_reset(void)
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hr
);
goto
cleanup
;
}
...
...
@@ -975,8 +975,12 @@ static void test_scene(void)
hr
=
IDirect3D9_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
/* no NULLREF here */
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
hr
==
D3D_OK
,
"IDirect3D9_CreateDevice failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
if
(
!
pDevice
)
goto
cleanup
;
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_NOTAVAILABLE
,
"IDirect3D9_CreateDevice failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
if
(
!
pDevice
)
{
skip
(
"Failed to create a d3d device
\n
"
);
goto
cleanup
;
}
/* Get the caps, they will be needed to tell if an operation is supposed to be valid */
memset
(
&
caps
,
0
,
sizeof
(
caps
));
...
...
@@ -1124,8 +1128,12 @@ static void test_limits(void)
hr
=
IDirect3D9_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
/* no NULLREF here */
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
hr
==
D3D_OK
,
"IDirect3D9_CreateDevice failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
if
(
!
pDevice
)
goto
cleanup
;
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_NOTAVAILABLE
,
"IDirect3D9_CreateDevice failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
if
(
!
pDevice
)
{
skip
(
"Failed to create a d3d device
\n
"
);
goto
cleanup
;
}
hr
=
IDirect3DDevice9_CreateTexture
(
pDevice
,
16
,
16
,
1
,
0
,
D3DFMT_A8R8G8B8
,
D3DPOOL_MANAGED
,
&
pTexture
,
NULL
);
ok
(
hr
==
D3D_OK
,
"IDirect3DDevice9_CreateTexture failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
...
...
@@ -1187,8 +1195,12 @@ static void test_depthstenciltest(void)
hr
=
IDirect3D9_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
/* no NULLREF here */
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
hr
==
D3D_OK
,
"IDirect3D9_CreateDevice failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
if
(
!
pDevice
)
goto
cleanup
;
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_NOTAVAILABLE
,
"IDirect3D9_CreateDevice failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
if
(
!
pDevice
)
{
skip
(
"Failed to create a d3d device
\n
"
);
goto
cleanup
;
}
hr
=
IDirect3DDevice9_GetDepthStencilSurface
(
pDevice
,
&
pDepthStencil
);
ok
(
hr
==
D3D_OK
&&
pDepthStencil
!=
NULL
,
"IDirect3DDevice9_GetDepthStencilSurface failed with %s
\n
"
,
DXGetErrorString9
(
hr
));
...
...
dlls/d3d9/tests/query.c
View file @
9ae22f1a
...
...
@@ -96,8 +96,12 @@ static void test_query_support(IDirect3D9 *pD3d, HWND hwnd)
hr
=
IDirect3D9_CreateDevice
(
pD3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
hwnd
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
d3dpp
,
&
pDevice
);
ok
(
SUCCEEDED
(
hr
),
"Failed to create IDirect3D9Device (%s)
\n
"
,
DXGetErrorString9
(
hr
));
if
(
FAILED
(
hr
))
goto
cleanup
;
ok
(
SUCCEEDED
(
hr
)
||
hr
==
D3DERR_NOTAVAILABLE
,
"Failed to create IDirect3D9Device (%s)
\n
"
,
DXGetErrorString9
(
hr
));
if
(
FAILED
(
hr
))
{
skip
(
"Failed to create a d3d device
\n
"
);
goto
cleanup
;
}
for
(
i
=
0
;
i
<
sizeof
(
queries
)
/
sizeof
(
queries
[
0
]);
i
++
)
{
...
...
dlls/d3d9/tests/shader.c
View file @
9ae22f1a
...
...
@@ -58,7 +58,7 @@ static IDirect3DDevice9 *init_d3d9(void)
if
(
FAILED
(
hres
))
{
trace
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hres
);
skip
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hres
);
return
NULL
;
}
...
...
dlls/d3d9/tests/surface.c
View file @
9ae22f1a
...
...
@@ -57,7 +57,7 @@ static IDirect3DDevice9 *init_d3d9(HMODULE d3d9_handle)
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hr
);
return
NULL
;
}
...
...
dlls/d3d9/tests/texture.c
View file @
9ae22f1a
...
...
@@ -56,7 +56,7 @@ static IDirect3DDevice9 *init_d3d9(HMODULE d3d9_handle)
if
(
FAILED
(
hr
))
{
trace
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hr
);
skip
(
"could not create device, IDirect3D9_CreateDevice returned %#x
\n
"
,
hr
);
return
NULL
;
}
...
...
dlls/d3d9/tests/visual.c
View file @
9ae22f1a
...
...
@@ -120,7 +120,7 @@ static IDirect3DDevice9 *init_d3d9(void)
present_parameters
.
AutoDepthStencilFormat
=
D3DFMT_D16
;
hr
=
IDirect3D9_CreateDevice
(
d3d9_ptr
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
present_parameters
.
hDeviceWindow
,
D3DCREATE_SOFTWARE_VERTEXPROCESSING
,
&
present_parameters
,
&
device_ptr
);
ok
(
hr
==
D3D_OK
,
"IDirect3D_CreateDevice returned: %s
\n
"
,
DXGetErrorString9
(
hr
));
ok
(
hr
==
D3D_OK
||
hr
==
D3DERR_NOTAVAILABLE
,
"IDirect3D_CreateDevice returned: %s
\n
"
,
DXGetErrorString9
(
hr
));
return
device_ptr
;
}
...
...
@@ -1199,7 +1199,11 @@ START_TEST(visual)
}
device_ptr
=
init_d3d9
();
if
(
!
device_ptr
)
return
;
if
(
!
device_ptr
)
{
skip
(
"Creating the device failed
\n
"
);
return
;
}
IDirect3DDevice9_GetDeviceCaps
(
device_ptr
,
&
caps
);
...
...
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