Table of Contents

Method CreateRegularPolygonPath

Namespace
SkiaSharp.Extended
Assembly
SkiaSharp.Extended.dll

CreateRegularPolygonPath(float, int, bool, SKPathDirection)

Creates a regular polygon path inscribed in a circle of the specified radius, centered at the origin.

public static SKPath CreateRegularPolygonPath(float radius, int points, bool horizontalBase = true, SKPathDirection direction = SKPathDirection.Clockwise)

Parameters

radius float

The circumscribed circle radius.

points int

The number of vertices of the polygon.

horizontalBase bool

If true, rotates the polygon so the base edge is horizontal (for even-sided polygons).

direction SKPathDirection

The winding direction of the path.

Returns

SKPath

A new SKPath representing the regular polygon.