Skip to main content
`Ctrl`+`K`

# vispy.visuals.regular_polygon module

RegularPolygonVisual visual based on EllipseVisual

class vispy.visuals.regular_polygon.RegularPolygonVisual(center=None, color='black', border_color=None, border_width=1, radius=0.1, sides=4, **kwargs)

  Bases: `EllipseVisual`

  Displays a regular polygon

  Parameters:
    center array-like (x, y)

      Center of the regular polygon

    color str | tuple | list of colors

      Fill color of the polygon

    border_color str | tuple | list of colors

      Border color of the polygon

    border_width: float

      The width of the border in pixels

    radius float

      Radius of the regular polygon Defaults to 0.1

    sides int

      Number of sides of the regular polygon

  property sides

    The number of sides in the regular polygon.