---
title: "GdiGraphics..::.FillPie Method (Brush, Rectangle, Single, Single)"
canonical: https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_Drawing_GdiGraphics_FillPie_4_2e4bb6be.htm
product: "Graphics Mill 5.5 for .NET"
---

This documentation is for the old version. [Go to the latest Graphics Mill docs](https://www.graphicsmill.com/docs/gm/)

# GdiGraphics.FillPie Method (Brush, Rectangle, Single, Single)
 
Fills a pie shape.
 
**Namespace:** [Aurigma.GraphicsMill.Drawing](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill_Drawing.htm.md)
 **Assembly:** Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)
 
## Syntax
  
```
Public Sub FillPie ( _brush As Brush, _rect As Rectangle, _startAngle As Single, _sweepAngle As Single _
)
```
 
```csharp
public void FillPie(Brush brush,Rectangle rect,float startAngle,float sweepAngle
)
```
 
### Parameters
 
 - brush
     - Type: [Aurigma.GraphicsMill.Drawing.Brush](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Drawing_Brush.htm.md)
 [Brush](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Drawing_Brush.htm.md) object which is used to fill a pie.

 - rect
     - Type: [System.Drawing.Rectangle](http://msdn2.microsoft.com/en-us/1zk39146)
The bounding rectangle for the ellipse (see **Remarks** section).

 - startAngle
     - Type: [System.Single](http://msdn2.microsoft.com/en-us/3www918f)
An angle between x-axis and the first radial line which defines a sector on the ellipse.

 - sweepAngle
     - Type: [System.Single](http://msdn2.microsoft.com/en-us/3www918f)
An angle between first and second radial line which defines a sector on the ellipse.
 
## Remarks
  
Pie is an arc + two lines connecting arc ends with the center of the ellipse. In other words pie is defined with a tightest bounding rectangle of the ellipse and two angles which specifies necessary ellipse sector.
 
All the coordinates are measured in units specified with [Unit](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_UnitConverterObject_Unit.htm.md) property.
 
To outline a pie shape, use [DrawPie(Pen, Rectangle, Single, Single)](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_Drawing_GdiGraphics_DrawPie_4_46546171.htm.md) method.
   
## See Also

### Reference

- [GdiGraphics Class](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Drawing_GdiGraphics.htm.md)
- [FillPie Overload](https://www.graphicsmill.com/docs/gm5/O_T_Aurigma_GraphicsMill_Drawing_GdiGraphics_FillPie.htm.md)
- [Aurigma.GraphicsMill.Drawing Namespace](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill_Drawing.htm.md)
