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
6e0c574f
Commit
6e0c574f
authored
Jul 31, 2007
by
Evan Stade
Committed by
Alexandre Julliard
Aug 01, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdiplus: Extend GdipDrawImagePointsRect.
parent
5cde9607
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
7 deletions
+21
-7
graphics.c
dlls/gdiplus/graphics.c
+21
-7
No files found.
dlls/gdiplus/graphics.c
View file @
6e0c574f
...
...
@@ -1040,6 +1040,7 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
{
GpPointF
ptf
[
3
];
POINT
pti
[
3
];
REAL
dx
,
dy
;
TRACE
(
"%p %p %p %d %f %f %f %f %d %p %p %p
\n
"
,
graphics
,
image
,
points
,
count
,
srcx
,
srcy
,
srcwidth
,
srcheight
,
srcUnit
,
imageAttributes
,
callback
,
...
...
@@ -1048,20 +1049,33 @@ GpStatus WINGDIPAPI GdipDrawImagePointsRect(GpGraphics *graphics, GpImage *image
if
(
!
graphics
||
!
image
||
!
points
||
!
imageAttributes
||
count
!=
3
)
return
InvalidParameter
;
if
(
image
->
type
!=
ImageTypeMetafile
)
return
NotImplemented
;
if
((
points
[
0
].
X
!=
points
[
2
].
X
)
||
(
points
[
0
].
Y
!=
points
[
1
].
Y
))
return
NotImplemented
;
if
(
srcUnit
!=
UnitInch
)
if
(
srcUnit
==
UnitInch
)
dx
=
dy
=
(
REAL
)
INCH_HIMETRIC
;
else
if
(
srcUnit
==
UnitPixel
){
dx
=
((
REAL
)
INCH_HIMETRIC
)
/
((
REAL
)
GetDeviceCaps
(
graphics
->
hdc
,
LOGPIXELSX
));
dy
=
((
REAL
)
INCH_HIMETRIC
)
/
((
REAL
)
GetDeviceCaps
(
graphics
->
hdc
,
LOGPIXELSY
));
}
else
return
NotImplemented
;
memcpy
(
ptf
,
points
,
3
*
sizeof
(
GpPointF
));
transform_and_round_points
(
graphics
,
pti
,
ptf
,
3
);
/* IPicture renders bitmaps with the y-axis reversed
* FIXME: flipping for unknown image type might not be correct. */
if
(
image
->
type
!=
ImageTypeMetafile
){
INT
temp
;
temp
=
pti
[
0
].
y
;
pti
[
0
].
y
=
pti
[
2
].
y
;
pti
[
2
].
y
=
temp
;
}
if
(
IPicture_Render
(
image
->
picture
,
graphics
->
hdc
,
pti
[
0
].
x
,
pti
[
0
].
y
,
pti
[
1
].
x
-
pti
[
0
].
x
,
pti
[
2
].
y
-
pti
[
0
].
y
,
srcx
*
INCH_HIMETRIC
,
srcy
*
INCH_HIMETRIC
,
srcwidth
*
INCH_HIMETRIC
,
srcheight
*
INCH_HIMETRIC
,
srcx
*
dx
,
srcy
*
dy
,
srcwidth
*
dx
,
srcheight
*
dy
,
NULL
)
!=
S_OK
){
if
(
callback
)
callback
(
callbackData
);
...
...
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