Clipper:getUnion

From GiderosMobile
Revision as of 22:07, 14 November 2026 by MoKaLux (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Available since: Gideros 2015.03.22
Class: Clipper

Description

Computes the union of the subject and clip polygons.

(table) = Clipper:getUnion(fillType1,fillType2)

Parameters

fillType1: (number, optional, default = Polygon.FILL_EVEN_ODD) fill rule for the subject polygons
fillType2: (number, optional, default = Polygon.FILL_EVEN_ODD) fill rule for the clip polygons

Return values

Returns (table) array of Polygon objects (1 indexed) with the resulting polygons. May be empty when there is no overlap

Example

local res = clipper:getUnion(Polygon.FILL_EVEN_ODD, Polygon.FILL_EVEN_ODD)