Unicode Controls & Classes for VB6 - Version 4

clsGpGraphics.DrawPolygonI Function

Draws a polygon

Syntax
Public Function DrawPolygonI (ByRef oPn As clsGpPen, _
ByVal lpPointsL As Long, _
ByVal Count As Long) As GpStatus
Parameters
Parameter Description
ByRef oPn As clsGpPen The Pen to use
ByVal lpPointsL As Long The pointer of the array of POINTL to use for drawing the polygon (use 'ByVal VarPtr YourArray(0)') as parameter
ByVal Count As Long The number of points passed
Remarks
Dim oPn As New clsGpPen
Dim oBr As New clsGpBrush
Dim oGr As clsGpGraphics

oGr.CreateFromHDC lHdc

If bFilled Then
oBr.CreateSolidFill_RawColor moGPSes.ColorFromRGB(lColor, lColorAlpha)
oGr.FillPolygon2I oBr, ByVal VarPtr(aPoli(0)), UBound(aPoli) + 1 'Our array is defined 0 to 4 (so 5 items)
Else
oPn.Create1_RawColor moGPSes.ColorFromRGB(lColor, lColorAlpha), 1, UnitPixel
oGr.DrawPolygonI oPn, ByVal VarPtr(aPoli(0)), UBound(aPoli) + 1 'Our array is defined 0 to 4 (so 5 items)
End If

oPn.Dispose
oBr.Dispose
oGr.Dispose