Skip to content

Intermact API Reference / @intermact/core / polygon

Function: polygon()

polygon(props): IMObject2D

Defined in: packages/core/src/geometry/primitives.ts:220

Build a polygon from an explicit ordered point list (design.md §5.1). Each entry in holes becomes an inner contour subtracted via the even-odd/nonzero fill rule. A closed polygon (default) is fillable and morphable; an open one is a stroke-only path.

Parameters

props

PolygonProps

Returns

IMObject2D

Intermact v1.0 — 文档覆盖 Phase-1 / Phase-2 / Phase-3(全阶段)