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
2302e80c
Commit
2302e80c
authored
Mar 10, 2011
by
Vincent Povirk
Committed by
Alexandre Julliard
Mar 11, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdiplus: Don't use gdi32 to scale or draw from outside bitmaps.
parent
8b6dafda
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
8 deletions
+11
-8
graphics.c
dlls/gdiplus/graphics.c
+11
-8
No files found.
dlls/gdiplus/graphics.c
View file @
2302e80c
...
...
@@ -2465,10 +2465,18 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
else
return
NotImplemented
;
srcx
=
srcx
*
dx
;
srcy
=
srcy
*
dy
;
srcwidth
=
srcwidth
*
dx
;
srcheight
=
srcheight
*
dy
;
if
(
imageAttributes
||
(
graphics
->
image
&&
graphics
->
image
->
type
==
ImageTypeBitmap
)
||
!
((
GpBitmap
*
)
image
)
->
hbitmap
||
ptf
[
1
].
Y
!=
ptf
[
0
].
Y
||
ptf
[
2
].
X
!=
ptf
[
0
].
X
)
ptf
[
1
].
Y
!=
ptf
[
0
].
Y
||
ptf
[
2
].
X
!=
ptf
[
0
].
X
||
ptf
[
1
].
X
-
ptf
[
0
].
X
!=
srcwidth
||
ptf
[
2
].
Y
-
ptf
[
0
].
Y
!=
srcheight
||
srcx
<
0
||
srcy
<
0
||
srcx
+
srcwidth
>
bitmap
->
width
||
srcy
+
srcheight
>
bitmap
->
height
)
use_software
=
1
;
if
(
use_software
)
...
...
@@ -2488,11 +2496,6 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
if
(
!
imageAttributes
)
imageAttributes
=
&
defaultImageAttributes
;
srcx
=
srcx
*
dx
;
srcy
=
srcy
*
dy
;
srcwidth
=
srcwidth
*
dx
;
srcheight
=
srcheight
*
dy
;
dst_area
.
left
=
dst_area
.
right
=
pti
[
0
].
x
;
dst_area
.
top
=
dst_area
.
bottom
=
pti
[
0
].
y
;
for
(
i
=
1
;
i
<
4
;
i
++
)
...
...
@@ -2672,12 +2675,12 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
bf
.
AlphaFormat
=
AC_SRC_ALPHA
;
GdiAlphaBlend
(
graphics
->
hdc
,
pti
[
0
].
x
,
pti
[
0
].
y
,
pti
[
1
].
x
-
pti
[
0
].
x
,
pti
[
2
].
y
-
pti
[
0
].
y
,
hdc
,
srcx
*
dx
,
srcy
*
dy
,
srcwidth
*
dx
,
srcheight
*
dy
,
bf
);
hdc
,
srcx
,
srcy
,
srcwidth
,
srcheight
,
bf
);
}
else
{
StretchBlt
(
graphics
->
hdc
,
pti
[
0
].
x
,
pti
[
0
].
y
,
pti
[
1
].
x
-
pti
[
0
].
x
,
pti
[
2
].
y
-
pti
[
0
].
y
,
hdc
,
srcx
*
dx
,
srcy
*
dy
,
srcwidth
*
dx
,
srcheight
*
dy
,
SRCCOPY
);
hdc
,
srcx
,
srcy
,
srcwidth
,
srcheight
,
SRCCOPY
);
}
if
(
temp_hdc
)
...
...
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