#include <GDIPlus.au3>
#include <GUIConstantsEx.au3>
Example()
Func Example()
_GDIPlus_Startup() ;initialize GDI+
Local Const $iWidth = 600, $iHeight = 600, $iBgColor = 0x303030 ;$iBGColor format RRGGBB
Local $hGUI = GUICreate("GDI+ example", $iWidth, $iHeight) ;create a test GUI
GUISetBkColor($iBgColor, $hGUI) ;set GUI background color
GUISetState(@SW_SHOW)
Local $hGraphics = _GDIPlus_GraphicsCreateFromHWND($hGUI) ;create a graphics object from a window handle
_GDIPlus_GraphicsSetSmoothingMode($hGraphics, $GDIP_SMOOTHINGMODE_HIGHQUALITY) ;sets the graphics object rendering quality (antialiasing)
Local $hBrush1 = _GDIPlus_BrushCreateSolid(0xFF8080A0) ;color format AARRGGBB (hex)
Local $hBrush2 = _GDIPlus_BrushCreateSolid(0xFFDD8800) ;color format AARRGGBB (hex)
Local $hBrush3 = _GDIPlus_BrushCreateSolid(0xFFDD0088) ;color format AARRGGBB (hex)
_GDIPlus_GraphicsFillPie($hGraphics, 115, 105, 400.75, 400.125, 45, 360, $hBrush1)
_GDIPlus_GraphicsFillPie($hGraphics, 115, 105, 400.75, 400.125, 45, 200, $hBrush2)
_GDIPlus_GraphicsFillPie($hGraphics, 115, 105, 400.75, 400.125, 45, 90, $hBrush3)
Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE
;cleanup GDI+ resources
_GDIPlus_PenDispose($hBrush3)
_GDIPlus_PenDispose($hBrush2)
_GDIPlus_PenDispose($hBrush1)
_GDIPlus_GraphicsDispose($hGraphics)
_GDIPlus_Shutdown()
GUIDelete($hGUI)
EndFunc ;==>Example