Evan Stade : gdiplus: Added GdipS/GetPathGradientGammaCorrection.
Alexandre Julliard
julliard at wine.codeweavers.com
Fri Aug 3 08:04:50 CDT 2007
Module: wine
Branch: master
Commit: 9ea7ef468b1911393bf95e3d6359cef3ba9e3a6c
URL: http://source.winehq.org/git/wine.git/?a=commit;h=9ea7ef468b1911393bf95e3d6359cef3ba9e3a6c
Author: Evan Stade <estade at gmail.com>
Date: Thu Aug 2 17:52:49 2007 -0700
gdiplus: Added GdipS/GetPathGradientGammaCorrection.
---
dlls/gdiplus/brush.c | 24 ++++++++++++++++++++++++
dlls/gdiplus/gdiplus.spec | 4 ++--
dlls/gdiplus/gdiplus_private.h | 1 +
include/gdiplusflat.h | 2 ++
4 files changed, 29 insertions(+), 2 deletions(-)
diff --git a/dlls/gdiplus/brush.c b/dlls/gdiplus/brush.c
index 4864caf..d993119 100644
--- a/dlls/gdiplus/brush.c
+++ b/dlls/gdiplus/brush.c
@@ -84,6 +84,7 @@ GpStatus WINGDIPAPI GdipCreatePathGradient(GDIPCONST GpPointF* points,
(*grad)->brush.bt = BrushTypePathGradient;
(*grad)->centercolor = 0xffffffff;
(*grad)->wrap = wrap;
+ (*grad)->gamma = FALSE;
return Ok;
}
@@ -123,6 +124,7 @@ GpStatus WINGDIPAPI GdipCreatePathGradientFromPath(GDIPCONST GpPath* path,
(*grad)->brush.bt = BrushTypePathGradient;
(*grad)->centercolor = 0xffffffff;
(*grad)->wrap = WrapModeClamp;
+ (*grad)->gamma = FALSE;
return Ok;
}
@@ -166,6 +168,17 @@ GpStatus WINGDIPAPI GdipDeleteBrush(GpBrush *brush)
return Ok;
}
+GpStatus WINGDIPAPI GdipGetPathGradientGammaCorrection(GpPathGradient *grad,
+ BOOL *gamma)
+{
+ if(!grad || !gamma)
+ return InvalidParameter;
+
+ *gamma = grad->gamma;
+
+ return Ok;
+}
+
GpStatus WINGDIPAPI GdipGetPathGradientPointCount(GpPathGradient *grad,
INT *count)
{
@@ -216,6 +229,17 @@ GpStatus WINGDIPAPI GdipSetPathGradientCenterColor(GpPathGradient *grad,
return Ok;
}
+GpStatus WINGDIPAPI GdipSetPathGradientGammaCorrection(GpPathGradient *grad,
+ BOOL gamma)
+{
+ if(!grad)
+ return InvalidParameter;
+
+ grad->gamma = gamma;
+
+ return Ok;
+}
+
GpStatus WINGDIPAPI GdipSetPathGradientSigmaBlend(GpPathGradient *grad,
REAL focus, REAL scale)
{
diff --git a/dlls/gdiplus/gdiplus.spec b/dlls/gdiplus/gdiplus.spec
index a3da26a..467ba82 100644
--- a/dlls/gdiplus/gdiplus.spec
+++ b/dlls/gdiplus/gdiplus.spec
@@ -331,7 +331,7 @@
@ stub GdipGetPathGradientCenterPoint
@ stub GdipGetPathGradientCenterPointI
@ stub GdipGetPathGradientFocusScales
-@ stub GdipGetPathGradientGammaCorrection
+@ stdcall GdipGetPathGradientGammaCorrection(ptr ptr)
@ stub GdipGetPathGradientPath
@ stdcall GdipGetPathGradientPointCount(ptr ptr)
@ stub GdipGetPathGradientPresetBlend
@@ -553,7 +553,7 @@
@ stub GdipSetPathGradientCenterPoint
@ stub GdipSetPathGradientCenterPointI
@ stub GdipSetPathGradientFocusScales
-@ stub GdipSetPathGradientGammaCorrection
+@ stdcall GdipSetPathGradientGammaCorrection(ptr long)
@ stub GdipSetPathGradientLinearBlend
@ stub GdipSetPathGradientPath
@ stub GdipSetPathGradientPresetBlend
diff --git a/dlls/gdiplus/gdiplus_private.h b/dlls/gdiplus/gdiplus_private.h
index 1c59a59..5f92680 100644
--- a/dlls/gdiplus/gdiplus_private.h
+++ b/dlls/gdiplus/gdiplus_private.h
@@ -97,6 +97,7 @@ struct GpPathGradient{
PathData pathdata;
ARGB centercolor;
GpWrapMode wrap;
+ BOOL gamma;
};
struct GpPath{
diff --git a/include/gdiplusflat.h b/include/gdiplusflat.h
index 87b8ccb..35edfba 100644
--- a/include/gdiplusflat.h
+++ b/include/gdiplusflat.h
@@ -94,12 +94,14 @@ GpStatus WINGDIPAPI GdipCreatePathGradientFromPath(GDIPCONST GpPath*,
GpPathGradient**);
GpStatus WINGDIPAPI GdipCreateSolidFill(ARGB,GpSolidFill**);
GpStatus WINGDIPAPI GdipGetBrushType(GpBrush*,GpBrushType*);
+GpStatus WINGDIPAPI GdipGetPathGradientGammaCorrection(GpPathGradient*,BOOL*);
GpStatus WINGDIPAPI GdipGetPathGradientPointCount(GpPathGradient*,INT*);
GpStatus WINGDIPAPI GdipGetPathGradientSurroundColorsWithCount(GpPathGradient*,
ARGB*,INT*);
GpStatus WINGDIPAPI GdipDeleteBrush(GpBrush*);
GpStatus WINGDIPAPI GdipGetSolidFillColor(GpSolidFill*,ARGB*);
GpStatus WINGDIPAPI GdipSetPathGradientCenterColor(GpPathGradient*,ARGB);
+GpStatus WINGDIPAPI GdipSetPathGradientGammaCorrection(GpPathGradient*,BOOL);
GpStatus WINGDIPAPI GdipSetPathGradientSigmaBlend(GpPathGradient*,REAL,REAL);
GpStatus WINGDIPAPI GdipSetPathGradientSurroundColorsWithCount(GpPathGradient*,
ARGB*,INT*);
More information about the wine-cvs
mailing list