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
7029559e
Commit
7029559e
authored
Sep 23, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Avoid rounding errors with visible rectangles in mirroring blits.
parent
527a985a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
8 deletions
+14
-8
bitblt.c
dlls/gdi32/bitblt.c
+14
-8
No files found.
dlls/gdi32/bitblt.c
View file @
7029559e
...
...
@@ -120,10 +120,13 @@ static BOOL get_vis_rectangles( DC *dc_dst, struct bitblt_coords *dst,
else
/* stretching */
{
/* map source rectangle into destination coordinates */
rect
.
left
=
dst
->
x
+
(
src
->
visrect
.
left
-
src
->
x
)
*
dst
->
width
/
src
->
width
;
rect
.
top
=
dst
->
y
+
(
src
->
visrect
.
top
-
src
->
y
)
*
dst
->
height
/
src
->
height
;
rect
.
right
=
dst
->
x
+
(
src
->
visrect
.
right
-
src
->
x
)
*
dst
->
width
/
src
->
width
;
rect
.
bottom
=
dst
->
y
+
(
src
->
visrect
.
bottom
-
src
->
y
)
*
dst
->
height
/
src
->
height
;
rect
=
src
->
visrect
;
offset_rect
(
&
rect
,
-
min
(
src
->
x
,
src
->
x
+
src
->
width
+
1
),
-
min
(
src
->
y
,
src
->
y
+
src
->
height
+
1
)
);
rect
.
left
=
dst
->
x
+
rect
.
left
*
dst
->
width
/
abs
(
src
->
width
);
rect
.
top
=
dst
->
y
+
rect
.
top
*
dst
->
height
/
abs
(
src
->
height
);
rect
.
right
=
dst
->
x
+
rect
.
right
*
dst
->
width
/
abs
(
src
->
width
);
rect
.
bottom
=
dst
->
y
+
rect
.
bottom
*
dst
->
height
/
abs
(
src
->
height
);
if
(
rect
.
left
>
rect
.
right
)
swap_ints
(
&
rect
.
left
,
&
rect
.
right
);
if
(
rect
.
top
>
rect
.
bottom
)
swap_ints
(
&
rect
.
top
,
&
rect
.
bottom
);
...
...
@@ -135,10 +138,13 @@ static BOOL get_vis_rectangles( DC *dc_dst, struct bitblt_coords *dst,
if
(
!
intersect_rect
(
&
dst
->
visrect
,
&
rect
,
&
dst
->
visrect
))
return
FALSE
;
/* map destination rectangle back to source coordinates */
rect
.
left
=
src
->
x
+
(
dst
->
visrect
.
left
-
dst
->
x
)
*
src
->
width
/
dst
->
width
;
rect
.
top
=
src
->
y
+
(
dst
->
visrect
.
top
-
dst
->
y
)
*
src
->
height
/
dst
->
height
;
rect
.
right
=
src
->
x
+
(
dst
->
visrect
.
right
-
dst
->
x
)
*
src
->
width
/
dst
->
width
;
rect
.
bottom
=
src
->
y
+
(
dst
->
visrect
.
bottom
-
dst
->
y
)
*
src
->
height
/
dst
->
height
;
rect
=
dst
->
visrect
;
offset_rect
(
&
rect
,
-
min
(
dst
->
x
,
dst
->
x
+
dst
->
width
+
1
),
-
min
(
dst
->
y
,
dst
->
y
+
dst
->
height
+
1
)
);
rect
.
left
=
src
->
x
+
rect
.
left
*
src
->
width
/
abs
(
dst
->
width
);
rect
.
top
=
src
->
y
+
rect
.
top
*
src
->
height
/
abs
(
dst
->
height
);
rect
.
right
=
src
->
x
+
rect
.
right
*
src
->
width
/
abs
(
dst
->
width
);
rect
.
bottom
=
src
->
y
+
rect
.
bottom
*
src
->
height
/
abs
(
dst
->
height
);
if
(
rect
.
left
>
rect
.
right
)
swap_ints
(
&
rect
.
left
,
&
rect
.
right
);
if
(
rect
.
top
>
rect
.
bottom
)
swap_ints
(
&
rect
.
top
,
&
rect
.
bottom
);
...
...
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