Commit 60cad235 authored by Evan Stade's avatar Evan Stade Committed by Alexandre Julliard

gdiplus: Added compositing quality.

parent 53e17d29
......@@ -235,7 +235,7 @@
@ stub GdipGetClipBounds
@ stub GdipGetClipBoundsI
@ stub GdipGetCompositingMode
@ stub GdipGetCompositingQuality
@ stdcall GdipGetCompositingQuality(ptr ptr)
@ stub GdipGetCustomLineCapBaseCap
@ stub GdipGetCustomLineCapBaseInset
@ stub GdipGetCustomLineCapStrokeCaps
......@@ -493,7 +493,7 @@
@ stub GdipSetClipRectI
@ stub GdipSetClipRegion
@ stub GdipSetCompositingMode
@ stub GdipSetCompositingQuality
@ stdcall GdipSetCompositingQuality(ptr long)
@ stub GdipSetCustomLineCapBaseCap
@ stub GdipSetCustomLineCapBaseInset
@ stub GdipSetCustomLineCapStrokeCaps
......
......@@ -55,6 +55,7 @@ struct GpGraphics{
HDC hdc;
HWND hwnd;
SmoothingMode smoothing;
CompositingQuality compqual;
};
struct GpBrush{
......
......@@ -543,6 +543,7 @@ GpStatus WINGDIPAPI GdipCreateFromHDC(HDC hdc, GpGraphics **graphics)
(*graphics)->hdc = hdc;
(*graphics)->hwnd = NULL;
(*graphics)->smoothing = SmoothingModeDefault;
(*graphics)->compqual = CompositingQualityDefault;
return Ok;
}
......@@ -798,6 +799,18 @@ GpStatus WINGDIPAPI GdipFillPie(GpGraphics *graphics, GpBrush *brush, REAL x,
width, height, startAngle, sweepAngle);
}
/* FIXME: Compositing quality is not used anywhere except the getter/setter. */
GpStatus WINGDIPAPI GdipGetCompositingQuality(GpGraphics *graphics,
CompositingQuality *quality)
{
if(!graphics || !quality)
return InvalidParameter;
*quality = graphics->compqual;
return Ok;
}
/* FIXME: Smoothing mode is not used anywhere except the getter/setter. */
GpStatus WINGDIPAPI GdipGetSmoothingMode(GpGraphics *graphics, SmoothingMode *mode)
{
......@@ -809,6 +822,17 @@ GpStatus WINGDIPAPI GdipGetSmoothingMode(GpGraphics *graphics, SmoothingMode *mo
return Ok;
}
GpStatus WINGDIPAPI GdipSetCompositingQuality(GpGraphics *graphics,
CompositingQuality quality)
{
if(!graphics)
return InvalidParameter;
graphics->compqual = quality;
return Ok;
}
GpStatus WINGDIPAPI GdipSetSmoothingMode(GpGraphics *graphics, SmoothingMode mode)
{
if(!graphics)
......
......@@ -99,6 +99,16 @@ enum SmoothingMode
SmoothingModeAntiAlias
};
enum CompositingQuality
{
CompositingQualityInvalid = QualityModeInvalid,
CompositingQualityDefault = QualityModeDefault,
CompositingQualityHighSpeed = QualityModeLow,
CompositingQualityHighQuality = QualityModeHigh,
CompositingQualityGammaCorrected,
CompositingQualityAssumeLinear
};
#ifndef __cplusplus
typedef enum Unit Unit;
......@@ -109,6 +119,7 @@ typedef enum PathPointType PathPointType;
typedef enum LineJoin LineJoin;
typedef enum QualityMode QualityMode;
typedef enum SmoothingMode SmoothingMode;
typedef enum CompositingQuality CompositingQuality;
#endif /* end of c typedefs */
......
......@@ -45,7 +45,9 @@ GpStatus WINGDIPAPI GdipDrawPath(GpGraphics*,GpPen*,GpPath*);
GpStatus WINGDIPAPI GdipDrawPie(GpGraphics*,GpPen*,REAL,REAL,REAL,REAL,REAL,REAL);
GpStatus WINGDIPAPI GdipDrawRectangleI(GpGraphics*,GpPen*,INT,INT,INT,INT);
GpStatus WINGDIPAPI GdipFillPie(GpGraphics*,GpBrush*,REAL,REAL,REAL,REAL,REAL,REAL);
GpStatus WINGDIPAPI GdipGetCompositingQuality(GpGraphics*,CompositingQuality*);
GpStatus WINGDIPAPI GdipGetSmoothingMode(GpGraphics*,SmoothingMode*);
GpStatus WINGDIPAPI GdipSetCompositingQuality(GpGraphics*,CompositingQuality);
GpStatus WINGDIPAPI GdipSetSmoothingMode(GpGraphics*,SmoothingMode);
GpStatus WINGDIPAPI GdipCreateSolidFill(ARGB,GpSolidFill**);
......
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