Commit 47a605ef authored by Evan Stade's avatar Evan Stade Committed by Alexandre Julliard

gdiplus: Added GdipTransformMatrixPoints.

parent f28262b4
......@@ -582,7 +582,7 @@
@ stub GdipStringFormatGetGenericDefault
@ stub GdipStringFormatGetGenericTypographic
@ stub GdipTestControl
@ stub GdipTransformMatrixPoints
@ stdcall GdipTransformMatrixPoints(ptr ptr long)
@ stub GdipTransformMatrixPointsI
@ stub GdipTransformPath
@ stub GdipTransformPoints
......
......@@ -56,3 +56,24 @@ GpStatus WINGDIPAPI GdipDeleteMatrix(GpMatrix *matrix)
return Ok;
}
GpStatus WINGDIPAPI GdipTransformMatrixPoints(GpMatrix *matrix, GpPointF *pts,
INT count)
{
REAL x, y;
INT i;
if(!matrix || !pts)
return InvalidParameter;
for(i = 0; i < count; i++)
{
x = pts[i].X;
y = pts[i].Y;
pts[i].X = x * matrix->matrix[0] + y * matrix->matrix[2] + matrix->matrix[4];
pts[i].Y = x * matrix->matrix[1] + y * matrix->matrix[3] + matrix->matrix[5];
}
return Ok;
}
......@@ -62,6 +62,7 @@ GpStatus WINGDIPAPI GdipStartPathFigure(GpPath*);
GpStatus WINGDIPAPI GdipCreateMatrix2(REAL,REAL,REAL,REAL,REAL,REAL,GpMatrix**);
GpStatus WINGDIPAPI GdipDeleteMatrix(GpMatrix*);
GpStatus WINGDIPAPI GdipTransformMatrixPoints(GpMatrix*,GpPointF*,INT);
#ifdef __cplusplus
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment