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
f33aacd4
Commit
f33aacd4
authored
Oct 20, 2014
by
Stefan Dösinger
Committed by
Alexandre Julliard
Oct 21, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d8/tests: Update create_device to match d3d9.
parent
ee073386
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
device.c
dlls/d3d8/tests/device.c
+10
-8
No files found.
dlls/d3d8/tests/device.c
View file @
f33aacd4
...
@@ -31,12 +31,14 @@ struct vec3
...
@@ -31,12 +31,14 @@ struct vec3
float
x
,
y
,
z
;
float
x
,
y
,
z
;
};
};
#define CREATE_DEVICE_FULLSCREEN 0x01
struct
device_desc
struct
device_desc
{
{
HWND
device_window
;
HWND
device_window
;
unsigned
int
width
;
unsigned
int
width
;
unsigned
int
height
;
unsigned
int
height
;
BOOL
windowed
;
DWORD
flags
;
};
};
#define GET_X_LPARAM(lp) ((int)(short)LOWORD(lp))
#define GET_X_LPARAM(lp) ((int)(short)LOWORD(lp))
...
@@ -105,7 +107,7 @@ static IDirect3DDevice8 *create_device(IDirect3D8 *d3d8, HWND focus_window, cons
...
@@ -105,7 +107,7 @@ static IDirect3DDevice8 *create_device(IDirect3D8 *d3d8, HWND focus_window, cons
present_parameters
.
BackBufferWidth
=
desc
->
width
;
present_parameters
.
BackBufferWidth
=
desc
->
width
;
present_parameters
.
BackBufferHeight
=
desc
->
height
;
present_parameters
.
BackBufferHeight
=
desc
->
height
;
present_parameters
.
hDeviceWindow
=
desc
->
device_window
;
present_parameters
.
hDeviceWindow
=
desc
->
device_window
;
present_parameters
.
Windowed
=
desc
->
windowed
;
present_parameters
.
Windowed
=
!
(
desc
->
flags
&
CREATE_DEVICE_FULLSCREEN
)
;
}
}
if
(
SUCCEEDED
(
IDirect3D8_CreateDevice
(
d3d8
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
focus_window
,
if
(
SUCCEEDED
(
IDirect3D8_CreateDevice
(
d3d8
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
focus_window
,
...
@@ -2265,7 +2267,7 @@ static void test_wndproc(void)
...
@@ -2265,7 +2267,7 @@ static void test_wndproc(void)
device_desc
.
device_window
=
device_window
;
device_desc
.
device_window
=
device_window
;
device_desc
.
width
=
screen_width
;
device_desc
.
width
=
screen_width
;
device_desc
.
height
=
screen_height
;
device_desc
.
height
=
screen_height
;
device_desc
.
windowed
=
FALSE
;
device_desc
.
flags
=
CREATE_DEVICE_FULLSCREEN
;
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
{
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
...
@@ -2408,7 +2410,7 @@ static void test_wndproc_windowed(void)
...
@@ -2408,7 +2410,7 @@ static void test_wndproc_windowed(void)
device_desc
.
device_window
=
device_window
;
device_desc
.
device_window
=
device_window
;
device_desc
.
width
=
640
;
device_desc
.
width
=
640
;
device_desc
.
height
=
480
;
device_desc
.
height
=
480
;
device_desc
.
windowed
=
TRUE
;
device_desc
.
flags
=
0
;
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
{
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
...
@@ -2783,7 +2785,7 @@ static void test_window_style(void)
...
@@ -2783,7 +2785,7 @@ static void test_window_style(void)
device_desc
.
device_window
=
device_window
;
device_desc
.
device_window
=
device_window
;
device_desc
.
width
=
screen_width
;
device_desc
.
width
=
screen_width
;
device_desc
.
height
=
screen_height
;
device_desc
.
height
=
screen_height
;
device_desc
.
windowed
=
FALSE
;
device_desc
.
flags
=
CREATE_DEVICE_FULLSCREEN
;
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
{
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
...
@@ -2988,7 +2990,7 @@ static void test_mode_change(void)
...
@@ -2988,7 +2990,7 @@ static void test_mode_change(void)
device_desc
.
device_window
=
device_window
;
device_desc
.
device_window
=
device_window
;
device_desc
.
width
=
screen_width
;
device_desc
.
width
=
screen_width
;
device_desc
.
height
=
screen_height
;
device_desc
.
height
=
screen_height
;
device_desc
.
windowed
=
FALSE
;
device_desc
.
flags
=
CREATE_DEVICE_FULLSCREEN
;
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
{
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
...
@@ -3086,7 +3088,7 @@ static void test_device_window_reset(void)
...
@@ -3086,7 +3088,7 @@ static void test_device_window_reset(void)
device_desc
.
device_window
=
NULL
;
device_desc
.
device_window
=
NULL
;
device_desc
.
width
=
screen_width
;
device_desc
.
width
=
screen_width
;
device_desc
.
height
=
screen_height
;
device_desc
.
height
=
screen_height
;
device_desc
.
windowed
=
FALSE
;
device_desc
.
flags
=
CREATE_DEVICE_FULLSCREEN
;
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
if
(
!
(
device
=
create_device
(
d3d8
,
focus_window
,
&
device_desc
)))
{
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
...
@@ -6353,7 +6355,7 @@ static void test_lost_device(void)
...
@@ -6353,7 +6355,7 @@ static void test_lost_device(void)
device_desc
.
device_window
=
window
;
device_desc
.
device_window
=
window
;
device_desc
.
width
=
screen_width
;
device_desc
.
width
=
screen_width
;
device_desc
.
height
=
screen_height
;
device_desc
.
height
=
screen_height
;
device_desc
.
windowed
=
FALSE
;
device_desc
.
flags
=
CREATE_DEVICE_FULLSCREEN
;
if
(
!
(
device
=
create_device
(
d3d
,
window
,
&
device_desc
)))
if
(
!
(
device
=
create_device
(
d3d
,
window
,
&
device_desc
)))
{
{
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
skip
(
"Failed to create a D3D device, skipping tests.
\n
"
);
...
...
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