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
f719ef38
Commit
f719ef38
authored
Apr 17, 2014
by
Henri Verbeet
Committed by
Alexandre Julliard
Apr 17, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d8/tests: Use a separate device for texop_test().
parent
8cd5f7fd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
7 deletions
+24
-7
visual.c
dlls/d3d8/tests/visual.c
+24
-7
No files found.
dlls/d3d8/tests/visual.c
View file @
f719ef38
...
...
@@ -2287,14 +2287,18 @@ out:
IDirect3D8_Release
(
d3d
);
}
static
void
texop_test
(
IDirect3DDevice8
*
device
)
static
void
texop_test
(
void
)
{
IDirect3DTexture8
*
texture
=
NULL
;
IDirect3DTexture8
*
texture
;
D3DLOCKED_RECT
locked_rect
;
IDirect3DDevice8
*
device
;
IDirect3D8
*
d3d
;
unsigned
int
i
;
D3DCOLOR
color
;
ULONG
refcount
;
D3DCAPS8
caps
;
HWND
window
;
HRESULT
hr
;
unsigned
int
i
;
static
const
struct
{
float
x
,
y
,
z
;
...
...
@@ -2340,6 +2344,16 @@ static void texop_test(IDirect3DDevice8 *device)
{
D3DTOP_LERP
,
"LERP"
,
D3DTEXOPCAPS_LERP
,
D3DCOLOR_ARGB
(
0x00
,
0x00
,
0x33
,
0x33
)},
};
window
=
CreateWindowA
(
"static"
,
"d3d8_test"
,
WS_OVERLAPPEDWINDOW
|
WS_VISIBLE
,
0
,
0
,
640
,
480
,
NULL
,
NULL
,
NULL
,
NULL
);
d3d
=
Direct3DCreate8
(
D3D_SDK_VERSION
);
ok
(
!!
d3d
,
"Failed to create a D3D object.
\n
"
);
if
(
!
(
device
=
create_device
(
d3d
,
window
,
window
,
TRUE
)))
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
goto
done
;
}
memset
(
&
caps
,
0
,
sizeof
(
caps
));
hr
=
IDirect3DDevice8_GetDeviceCaps
(
device
,
&
caps
);
ok
(
SUCCEEDED
(
hr
),
"GetDeviceCaps failed with 0x%08x
\n
"
,
hr
);
...
...
@@ -2408,9 +2422,12 @@ static void texop_test(IDirect3DDevice8 *device)
ok
(
SUCCEEDED
(
hr
),
"IDirect3DDevice9_Clear failed with 0x%08x
\n
"
,
hr
);
}
hr
=
IDirect3DDevice8_SetTexture
(
device
,
0
,
NULL
);
ok
(
SUCCEEDED
(
hr
),
"SetTexture failed with 0x%08x
\n
"
,
hr
);
if
(
texture
)
IDirect3DTexture8_Release
(
texture
);
IDirect3DTexture8_Release
(
texture
);
refcount
=
IDirect3DDevice8_Release
(
device
);
ok
(
!
refcount
,
"Device has %u references left.
\n
"
,
refcount
);
done:
IDirect3D8_Release
(
d3d
);
DestroyWindow
(
window
);
}
/* This test tests depth clamping / clipping behaviour:
...
...
@@ -4859,7 +4876,6 @@ START_TEST(visual)
}
p8_texture_test
(
device_ptr
);
texop_test
(
device_ptr
);
refcount
=
IDirect3DDevice8_Release
(
device_ptr
);
ok
(
!
refcount
,
"Device has %u references left.
\n
"
,
refcount
);
...
...
@@ -4867,6 +4883,7 @@ cleanup:
IDirect3D8_Release
(
d3d
);
DestroyWindow
(
window
);
texop_test
();
depth_buffer_test
();
depth_buffer2_test
();
intz_test
();
...
...
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