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
f696e431
Commit
f696e431
authored
Sep 19, 2016
by
Vincent Povirk
Committed by
Alexandre Julliard
Sep 20, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdiplus: Add clipping to GdipDrawImage.
Signed-off-by:
Vincent Povirk
<
vincent@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
c6afa50d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
graphics.c
dlls/gdiplus/graphics.c
+14
-0
No files found.
dlls/gdiplus/graphics.c
View file @
f696e431
...
...
@@ -3083,6 +3083,8 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
HDC
hdc
;
BOOL
temp_hdc
=
FALSE
,
temp_bitmap
=
FALSE
;
HBITMAP
hbitmap
,
old_hbm
=
NULL
;
HRGN
hrgn
;
INT
save_state
;
if
(
!
(
bitmap
->
format
==
PixelFormat16bppRGB555
||
bitmap
->
format
==
PixelFormat24bppRGB
||
...
...
@@ -3143,6 +3145,16 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
old_hbm
=
SelectObject
(
hdc
,
hbitmap
);
}
save_state
=
SaveDC
(
graphics
->
hdc
);
stat
=
get_clip_hrgn
(
graphics
,
&
hrgn
);
if
(
stat
==
Ok
&&
hrgn
)
{
ExtSelectClipRgn
(
graphics
->
hdc
,
hrgn
,
RGN_AND
);
DeleteObject
(
hrgn
);
}
if
(
bitmap
->
format
&
(
PixelFormatAlpha
|
PixelFormatPAlpha
))
{
gdi_alpha_blend
(
graphics
,
pti
[
0
].
x
,
pti
[
0
].
y
,
pti
[
1
].
x
-
pti
[
0
].
x
,
pti
[
2
].
y
-
pti
[
0
].
y
,
...
...
@@ -3154,6 +3166,8 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
hdc
,
srcx
,
srcy
,
srcwidth
,
srcheight
,
SRCCOPY
);
}
RestoreDC
(
graphics
->
hdc
,
save_state
);
if
(
temp_hdc
)
{
SelectObject
(
hdc
,
old_hbm
);
...
...
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