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
ab1a53c1
Commit
ab1a53c1
authored
Jul 15, 2014
by
Henri Verbeet
Committed by
Alexandre Julliard
Jul 15, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d8/tests: Get rid of struct vertex.
parent
ce60e4ec
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
110 additions
and
81 deletions
+110
-81
visual.c
dlls/d3d8/tests/visual.c
+110
-81
No files found.
dlls/d3d8/tests/visual.c
View file @
ab1a53c1
...
...
@@ -133,12 +133,6 @@ static IDirect3DDevice8 *create_device(IDirect3D8 *d3d, HWND device_window, HWND
return
NULL
;
}
struct
vertex
{
float
x
,
y
,
z
;
DWORD
diffuse
;
};
struct
tvertex
{
float
x
,
y
,
z
,
w
;
...
...
@@ -205,19 +199,24 @@ static void lighting_test(void)
HWND
window
;
HRESULT
hr
;
static
const
struct
vertex
unlitquad
[]
=
static
const
struct
{
{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
1
f
,
0xffff0000
},
{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0xffff0000
},
{
0
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0xffff0000
},
{
0
.
0
f
,
-
1
.
0
f
,
0
.
1
f
,
0xffff0000
},
};
static
const
struct
vertex
litquad
[]
=
struct
vec3
position
;
DWORD
diffuse
;
}
unlitquad
[]
=
{
{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0xff00ff00
},
{
-
1
.
0
f
,
1
.
0
f
,
0
.
1
f
,
0xff00ff00
},
{
0
.
0
f
,
1
.
0
f
,
0
.
1
f
,
0xff00ff00
},
{
0
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0xff00ff00
},
{{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
1
f
},
0xffff0000
},
{{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
},
0xffff0000
},
{{
0
.
0
f
,
0
.
0
f
,
0
.
1
f
},
0xffff0000
},
{{
0
.
0
f
,
-
1
.
0
f
,
0
.
1
f
},
0xffff0000
},
},
litquad
[]
=
{
{{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
},
0xff00ff00
},
{{
-
1
.
0
f
,
1
.
0
f
,
0
.
1
f
},
0xff00ff00
},
{{
0
.
0
f
,
1
.
0
f
,
0
.
1
f
},
0xff00ff00
},
{{
0
.
0
f
,
0
.
0
f
,
0
.
1
f
},
0xff00ff00
},
};
static
const
struct
nvertex
unlitnquad
[]
=
{
...
...
@@ -754,12 +753,17 @@ static void fog_with_shader_test(void)
0x00000001
,
0x800f0000
,
0x90e40000
,
/* mov r0, v0 */
0x0000ffff
};
static
struct
vertex
quad
[]
=
static
struct
{
struct
vec3
position
;
DWORD
diffuse
;
}
quad
[]
=
{
{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
0
f
,
0xffff0000
},
{
-
1
.
0
f
,
1
.
0
f
,
0
.
0
f
,
0xffff0000
},
{
1
.
0
f
,
-
1
.
0
f
,
0
.
0
f
,
0xffff0000
},
{
1
.
0
f
,
1
.
0
f
,
0
.
0
f
,
0xffff0000
},
{
{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
0
f
}
,
0xffff0000
},
{
{
-
1
.
0
f
,
1
.
0
f
,
0
.
0
f
}
,
0xffff0000
},
{
{
1
.
0
f
,
-
1
.
0
f
,
0
.
0
f
}
,
0xffff0000
},
{
{
1
.
0
f
,
1
.
0
f
,
0
.
0
f
}
,
0xffff0000
},
};
static
const
DWORD
decl
[]
=
{
...
...
@@ -980,10 +984,10 @@ static void fog_with_shader_test(void)
for
(
j
=
0
;
j
<
11
;
++
j
)
{
/* Don't use the whole zrange to prevent rounding errors */
quad
[
0
].
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
1
].
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
2
].
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
3
].
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
0
].
position
.
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
1
].
position
.
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
2
].
position
.
z
=
0
.
001
f
+
j
/
10
.
02
f
;
quad
[
3
].
position
.
z
=
0
.
001
f
+
j
/
10
.
02
f
;
hr
=
IDirect3DDevice8_Clear
(
device
,
0
,
NULL
,
D3DCLEAR_TARGET
|
D3DCLEAR_ZBUFFER
,
0xffff00ff
,
1
.
0
f
,
0
);
ok
(
hr
==
D3D_OK
,
"IDirect3DDevice9_Clear failed (%08x)
\n
"
,
hr
);
...
...
@@ -1580,19 +1584,24 @@ static void z_range_test(void)
HWND
window
;
HRESULT
hr
;
static
const
struct
vertex
quad
[]
=
static
const
struct
{
{
-
1
.
0
f
,
0
.
0
f
,
1
.
1
f
,
0xffff0000
},
{
-
1
.
0
f
,
1
.
0
f
,
1
.
1
f
,
0xffff0000
},
{
1
.
0
f
,
0
.
0
f
,
-
1
.
1
f
,
0xffff0000
},
{
1
.
0
f
,
1
.
0
f
,
-
1
.
1
f
,
0xffff0000
},
};
static
const
struct
vertex
quad2
[]
=
struct
vec3
position
;
DWORD
diffuse
;
}
quad
[]
=
{
{{
-
1
.
0
f
,
0
.
0
f
,
1
.
1
f
},
0xffff0000
},
{{
-
1
.
0
f
,
1
.
0
f
,
1
.
1
f
},
0xffff0000
},
{{
1
.
0
f
,
0
.
0
f
,
-
1
.
1
f
},
0xffff0000
},
{{
1
.
0
f
,
1
.
0
f
,
-
1
.
1
f
},
0xffff0000
},
},
quad2
[]
=
{
{
-
1
.
0
f
,
0
.
0
f
,
1
.
1
f
,
0xff0000ff
},
{
-
1
.
0
f
,
1
.
0
f
,
1
.
1
f
,
0xff0000ff
},
{
1
.
0
f
,
0
.
0
f
,
-
1
.
1
f
,
0xff0000ff
},
{
1
.
0
f
,
1
.
0
f
,
-
1
.
1
f
,
0xff0000ff
},
{
{
-
1
.
0
f
,
0
.
0
f
,
1
.
1
f
}
,
0xff0000ff
},
{
{
-
1
.
0
f
,
1
.
0
f
,
1
.
1
f
}
,
0xff0000ff
},
{
{
1
.
0
f
,
0
.
0
f
,
-
1
.
1
f
}
,
0xff0000ff
},
{
{
1
.
0
f
,
1
.
0
f
,
-
1
.
1
f
}
,
0xff0000ff
},
};
static
const
struct
tvertex
quad3
[]
=
{
...
...
@@ -2108,19 +2117,24 @@ static void alpha_test(void)
HWND
window
;
HRESULT
hr
;
static
const
struct
vertex
quad1
[]
=
static
const
struct
{
{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
1
f
,
0x4000ff00
},
{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0x4000ff00
},
{
1
.
0
f
,
-
1
.
0
f
,
0
.
1
f
,
0x4000ff00
},
{
1
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0x4000ff00
},
};
static
const
struct
vertex
quad2
[]
=
struct
vec3
position
;
DWORD
diffuse
;
}
quad1
[]
=
{
{{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
1
f
},
0x4000ff00
},
{{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
},
0x4000ff00
},
{{
1
.
0
f
,
-
1
.
0
f
,
0
.
1
f
},
0x4000ff00
},
{{
1
.
0
f
,
0
.
0
f
,
0
.
1
f
},
0x4000ff00
},
},
quad2
[]
=
{
{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0xc00000ff
},
{
-
1
.
0
f
,
1
.
0
f
,
0
.
1
f
,
0xc00000ff
},
{
1
.
0
f
,
0
.
0
f
,
0
.
1
f
,
0xc00000ff
},
{
1
.
0
f
,
1
.
0
f
,
0
.
1
f
,
0xc00000ff
},
{
{
-
1
.
0
f
,
0
.
0
f
,
0
.
1
f
}
,
0xc00000ff
},
{
{
-
1
.
0
f
,
1
.
0
f
,
0
.
1
f
}
,
0xc00000ff
},
{
{
1
.
0
f
,
0
.
0
f
,
0
.
1
f
}
,
0xc00000ff
},
{
{
1
.
0
f
,
1
.
0
f
,
0
.
1
f
}
,
0xc00000ff
},
};
static
const
float
composite_quad
[][
5
]
=
{
...
...
@@ -2667,19 +2681,24 @@ static void depth_clamp_test(void)
{
42
.
0
f
,
108
.
0
f
,
10
.
0
f
,
1
.
0
f
,
0xffffffff
},
{
112
.
0
f
,
108
.
0
f
,
10
.
0
f
,
1
.
0
f
,
0xffffffff
},
};
static
const
struct
vertex
quad5
[]
=
static
const
struct
{
{
-
0
.
5
f
,
0
.
5
f
,
10
.
0
f
,
0xff14f914
},
{
0
.
5
f
,
0
.
5
f
,
10
.
0
f
,
0xff14f914
},
{
-
0
.
5
f
,
-
0
.
5
f
,
10
.
0
f
,
0xff14f914
},
{
0
.
5
f
,
-
0
.
5
f
,
10
.
0
f
,
0xff14f914
},
};
static
const
struct
vertex
quad6
[]
=
struct
vec3
position
;
DWORD
diffuse
;
}
quad5
[]
=
{
{{
-
0
.
5
f
,
0
.
5
f
,
10
.
0
f
},
0xff14f914
},
{{
0
.
5
f
,
0
.
5
f
,
10
.
0
f
},
0xff14f914
},
{{
-
0
.
5
f
,
-
0
.
5
f
,
10
.
0
f
},
0xff14f914
},
{{
0
.
5
f
,
-
0
.
5
f
,
10
.
0
f
},
0xff14f914
},
},
quad6
[]
=
{
{
-
1
.
0
f
,
0
.
5
f
,
10
.
0
f
,
0xfff91414
},
{
1
.
0
f
,
0
.
5
f
,
10
.
0
f
,
0xfff91414
},
{
-
1
.
0
f
,
0
.
25
f
,
10
.
0
f
,
0xfff91414
},
{
1
.
0
f
,
0
.
25
f
,
10
.
0
f
,
0xfff91414
},
{
{
-
1
.
0
f
,
0
.
5
f
,
10
.
0
f
},
0xfff91414
},
{
{
1
.
0
f
,
0
.
5
f
,
10
.
0
f
},
0xfff91414
},
{
{
-
1
.
0
f
,
0
.
25
f
,
10
.
0
f
},
0xfff91414
},
{
{
1
.
0
f
,
0
.
25
f
,
10
.
0
f
},
0xfff91414
},
};
window
=
CreateWindowA
(
"static"
,
"d3d8_test"
,
WS_OVERLAPPEDWINDOW
|
WS_VISIBLE
,
...
...
@@ -2803,26 +2822,31 @@ static void depth_buffer_test(void)
HWND
window
;
HRESULT
hr
;
static
const
struct
vertex
quad1
[]
=
static
const
struct
{
{
-
1
.
0
,
1
.
0
,
0
.
33
f
,
0xff00ff00
},
{
1
.
0
,
1
.
0
,
0
.
33
f
,
0xff00ff00
},
{
-
1
.
0
,
-
1
.
0
,
0
.
33
f
,
0xff00ff00
},
{
1
.
0
,
-
1
.
0
,
0
.
33
f
,
0xff00ff00
},
};
static
const
struct
vertex
quad2
[]
=
struct
vec3
position
;
DWORD
diffuse
;
}
quad1
[]
=
{
{
-
1
.
0
,
1
.
0
,
0
.
50
f
,
0xffff00ff
},
{
1
.
0
,
1
.
0
,
0
.
50
f
,
0xffff00ff
},
{
-
1
.
0
,
-
1
.
0
,
0
.
50
f
,
0xffff00ff
},
{
1
.
0
,
-
1
.
0
,
0
.
50
f
,
0xffff00ff
},
};
static
const
struct
vertex
quad3
[]
=
{{
-
1
.
0
f
,
1
.
0
f
,
0
.
33
f
},
0xff00ff00
},
{{
1
.
0
f
,
1
.
0
f
,
0
.
33
f
},
0xff00ff00
},
{{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
33
f
},
0xff00ff00
},
{{
1
.
0
f
,
-
1
.
0
f
,
0
.
33
f
},
0xff00ff00
},
},
quad2
[]
=
{
{{
-
1
.
0
f
,
1
.
0
f
,
0
.
50
f
},
0xffff00ff
},
{{
1
.
0
f
,
1
.
0
f
,
0
.
50
f
},
0xffff00ff
},
{{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
50
f
},
0xffff00ff
},
{{
1
.
0
f
,
-
1
.
0
f
,
0
.
50
f
},
0xffff00ff
},
},
quad3
[]
=
{
{
-
1
.
0
,
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
1
.
0
,
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
-
1
.
0
,
-
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
1
.
0
,
-
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
{
-
1
.
0
f
,
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
{
{
1
.
0
f
,
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
{
{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
{
{
1
.
0
f
,
-
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
};
static
const
DWORD
expected_colors
[
4
][
4
]
=
{
...
...
@@ -2959,12 +2983,17 @@ static void depth_buffer2_test(void)
HWND
window
;
HRESULT
hr
;
static
const
struct
vertex
quad
[]
=
static
const
struct
{
struct
vec3
position
;
DWORD
diffuse
;
}
quad
[]
=
{
{
-
1
.
0
,
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
1
.
0
,
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
-
1
.
0
,
-
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
1
.
0
,
-
1
.
0
,
0
.
66
f
,
0xffff0000
},
{
{
-
1
.
0
f
,
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
{
{
1
.
0
f
,
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
{
{
-
1
.
0
f
,
-
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
{
{
1
.
0
f
,
-
1
.
0
f
,
0
.
66
f
}
,
0xffff0000
},
};
window
=
CreateWindowA
(
"static"
,
"d3d8_test"
,
WS_OVERLAPPEDWINDOW
|
WS_VISIBLE
,
...
...
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