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
95b822d6
Commit
95b822d6
authored
Jun 19, 2012
by
Józef Kucia
Committed by
Alexandre Julliard
Jun 19, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9/tests: Improve test failure messages for check_dds_pixel_format.
parent
217c8b94
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
5 deletions
+12
-5
surface.c
dlls/d3dx9_36/tests/surface.c
+12
-5
No files found.
dlls/d3dx9_36/tests/surface.c
View file @
95b822d6
...
...
@@ -211,9 +211,12 @@ static void fill_dds_header(struct dds_header *header)
header
->
caps
=
DDS_CAPS_TEXTURE
;
}
static
void
check_dds_pixel_format
(
DWORD
flags
,
DWORD
fourcc
,
DWORD
bpp
,
DWORD
rmask
,
DWORD
gmask
,
DWORD
bmask
,
DWORD
amask
,
D3DFORMAT
expected_format
)
#define check_dds_pixel_format(flags, fourcc, bpp, rmask, gmask, bmask, amask, format) \
check_dds_pixel_format_(__LINE__, flags, fourcc, bpp, rmask, gmask, bmask, amask, format)
static
void
check_dds_pixel_format_
(
unsigned
int
line
,
DWORD
flags
,
DWORD
fourcc
,
DWORD
bpp
,
DWORD
rmask
,
DWORD
gmask
,
DWORD
bmask
,
DWORD
amask
,
D3DFORMAT
expected_format
)
{
HRESULT
hr
;
D3DXIMAGE_INFO
info
;
...
...
@@ -234,9 +237,13 @@ static void check_dds_pixel_format(DWORD flags, DWORD fourcc, DWORD bpp,
memset
(
dds
.
data
,
0
,
sizeof
(
dds
.
data
));
hr
=
D3DXGetImageInfoFromFileInMemory
(
&
dds
,
sizeof
(
dds
),
&
info
);
ok
(
hr
==
D3D_OK
,
"D3DXGetImageInfoFromFileInMemory returned %#x for pixel format %#x, expected %#x
\n
"
,
hr
,
expected_format
,
D3D_OK
);
ok_
(
__FILE__
,
line
)(
hr
==
D3D_OK
,
"D3DXGetImageInfoFromFileInMemory returned %#x for pixel format %#x, expected %#x
\n
"
,
hr
,
expected_format
,
D3D_OK
);
if
(
SUCCEEDED
(
hr
))
ok
(
info
.
Format
==
expected_format
,
"D3DXGetImageInfoFromFileInMemory returned format %#x, expected %#x
\n
"
,
info
.
Format
,
expected_format
);
{
ok_
(
__FILE__
,
line
)(
info
.
Format
==
expected_format
,
"D3DXGetImageInfoFromFileInMemory returned format %#x, expected %#x
\n
"
,
info
.
Format
,
expected_format
);
}
}
static
void
test_dds_header_handling
(
void
)
...
...
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