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
075ad8ea
Commit
075ad8ea
authored
May 13, 2011
by
Huw Davies
Committed by
Alexandre Julliard
May 13, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32/tests: Tests for Rectangle().
parent
cf290ea6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
0 deletions
+38
-0
dib.c
dlls/gdi32/tests/dib.c
+38
-0
No files found.
dlls/gdi32/tests/dib.c
View file @
075ad8ea
...
@@ -92,6 +92,7 @@ static const char *sha1_graphics_a8r8g8b8[] =
...
@@ -92,6 +92,7 @@ static const char *sha1_graphics_a8r8g8b8[] =
"b2261353decda2712b83538ab434a49ce21f3172"
,
"b2261353decda2712b83538ab434a49ce21f3172"
,
"a8b59f25984b066fc6b91cae6bf983a78028ba7f"
,
"a8b59f25984b066fc6b91cae6bf983a78028ba7f"
,
"3d95adb85b9673a932ac847a4b5451fa59885f74"
,
"3d95adb85b9673a932ac847a4b5451fa59885f74"
,
"e2a8eef4aeda3a0f6c950075acba38f1f9e0814d"
,
NULL
NULL
};
};
...
@@ -242,6 +243,24 @@ static const RECT patblt_clips[] =
...
@@ -242,6 +243,24 @@ static const RECT patblt_clips[] =
{
170
,
200
,
176
,
210
},
/* t edge on b edgecase clipped */
{
170
,
200
,
176
,
210
},
/* t edge on b edgecase clipped */
};
};
static
const
RECT
rectangles
[]
=
{
{
10
,
11
,
100
,
101
},
{
250
,
100
,
350
,
10
},
{
120
,
10
,
120
,
20
},
/* zero width */
{
120
,
10
,
130
,
10
},
/* zero height */
{
120
,
40
,
121
,
41
},
/* 1 x 1 */
{
130
,
50
,
132
,
52
},
/* 2 x 2 */
{
140
,
60
,
143
,
63
},
/* 3 x 3 */
{
150
,
70
,
154
,
74
},
/* 4 x 4 */
{
120
,
20
,
121
,
30
},
/* width == 1 */
{
130
,
20
,
132
,
30
},
/* width == 2 */
{
140
,
20
,
143
,
30
},
/* width == 3 */
{
200
,
20
,
210
,
21
},
/* height == 1 */
{
200
,
30
,
210
,
32
},
/* height == 2 */
{
200
,
40
,
210
,
43
}
/* height == 3 */
};
static
const
BITMAPINFOHEADER
dib_brush_header_32
=
{
sizeof
(
BITMAPINFOHEADER
),
16
,
-
16
,
1
,
32
,
BI_RGB
,
0
,
0
,
0
,
0
,
0
};
static
const
BITMAPINFOHEADER
dib_brush_header_32
=
{
sizeof
(
BITMAPINFOHEADER
),
16
,
-
16
,
1
,
32
,
BI_RGB
,
0
,
0
,
0
,
0
,
0
};
static
void
draw_graphics
(
HDC
hdc
,
BITMAPINFO
*
bmi
,
BYTE
*
bits
,
const
char
***
sha1
)
static
void
draw_graphics
(
HDC
hdc
,
BITMAPINFO
*
bmi
,
BYTE
*
bits
,
const
char
***
sha1
)
...
@@ -480,6 +499,25 @@ static void draw_graphics(HDC hdc, BITMAPINFO *bmi, BYTE *bits, const char ***sh
...
@@ -480,6 +499,25 @@ static void draw_graphics(HDC hdc, BITMAPINFO *bmi, BYTE *bits, const char ***sh
SetBrushOrgEx
(
hdc
,
0
,
0
,
NULL
);
SetBrushOrgEx
(
hdc
,
0
,
0
,
NULL
);
/* Rectangle */
SelectObject
(
hdc
,
solid_pen
);
SelectObject
(
hdc
,
solid_brush
);
for
(
i
=
0
;
i
<
sizeof
(
rectangles
)
/
sizeof
(
rectangles
[
0
]);
i
++
)
{
Rectangle
(
hdc
,
rectangles
[
i
].
left
,
rectangles
[
i
].
top
,
rectangles
[
i
].
right
,
rectangles
[
i
].
bottom
);
}
SelectObject
(
hdc
,
dashed_pen
);
for
(
i
=
0
;
i
<
sizeof
(
rectangles
)
/
sizeof
(
rectangles
[
0
]);
i
++
)
{
Rectangle
(
hdc
,
rectangles
[
i
].
left
,
rectangles
[
i
].
top
+
150
,
rectangles
[
i
].
right
,
rectangles
[
i
].
bottom
+
150
);
}
compare_hash
(
bmi
,
bits
,
sha1
,
"rectangles"
);
memset
(
bits
,
0xcc
,
dib_size
);
SelectObject
(
hdc
,
orig_brush
);
SelectObject
(
hdc
,
orig_brush
);
SelectObject
(
hdc
,
orig_pen
);
SelectObject
(
hdc
,
orig_pen
);
DeleteObject
(
dib_brush
);
DeleteObject
(
dib_brush
);
...
...
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