Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
ebb31dbb
Commit
ebb31dbb
authored
Dec 05, 2008
by
Huw Davies
Committed by
Alexandre Julliard
Dec 05, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ddraw/tests: Skip tests if we can't create a primary surface.
parent
21bc015d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
2 deletions
+23
-2
dsurface.c
dlls/ddraw/tests/dsurface.c
+22
-0
visual.c
dlls/ddraw/tests/visual.c
+1
-2
No files found.
dlls/ddraw/tests/dsurface.c
View file @
ebb31dbb
...
...
@@ -2748,6 +2748,22 @@ static void SurfaceCapsTest(void)
}
}
static
BOOL
can_create_primary_surface
(
void
)
{
DDSURFACEDESC
ddsd
;
IDirectDrawSurface
*
surface
;
HRESULT
hr
;
memset
(
&
ddsd
,
0
,
sizeof
(
ddsd
));
ddsd
.
dwSize
=
sizeof
(
ddsd
);
ddsd
.
dwFlags
=
DDSD_CAPS
;
ddsd
.
ddsCaps
.
dwCaps
=
DDSCAPS_PRIMARYSURFACE
;
hr
=
IDirectDraw_CreateSurface
(
lpDD
,
&
ddsd
,
&
surface
,
NULL
);
if
(
FAILED
(
hr
))
return
FALSE
;
IDirectDrawSurface_Release
(
surface
);
return
TRUE
;
}
START_TEST
(
dsurface
)
{
HRESULT
ret
;
...
...
@@ -2765,6 +2781,12 @@ START_TEST(dsurface)
}
IDirectDraw_Release
(
dd4
);
if
(
!
can_create_primary_surface
())
{
skip
(
"Unable to create primary surface
\n
"
);
return
;
}
MipMapCreationTest
();
SrcColorKey32BlitTest
();
QueryInterface
();
...
...
dlls/ddraw/tests/visual.c
View file @
ebb31dbb
...
...
@@ -89,8 +89,7 @@ static BOOL createObjects(void)
ddsd
.
ddsCaps
.
dwCaps
=
DDSCAPS_PRIMARYSURFACE
|
DDSCAPS_3DDEVICE
;
ddsd
.
dwBackBufferCount
=
1
;
hr
=
IDirectDraw7_CreateSurface
(
DirectDraw
,
&
ddsd
,
&
Surface
,
NULL
);
ok
(
hr
==
DD_OK
,
"CreateSurface returned: %08x
\n
"
,
hr
);
if
(
!
Surface
)
goto
err
;
if
(
FAILED
(
hr
))
goto
err
;
hr
=
IDirect3D7_CreateDevice
(
Direct3D
,
&
IID_IDirect3DTnLHalDevice
,
Surface
,
&
Direct3DDevice
);
if
(
FAILED
(
hr
))
...
...
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