Skip to main content

Clip

Each feature cut by a mask (the union of its features): the part inside, as turf.intersect and a clip do, or the part outside, as turf.difference does. Features left with nothing are dropped. turf takes the first feature of each side; this cuts every feature by the whole mask.

Syntax​

{ "id": "n1", "op": "clip", "name": "clip", "x": 0, "y": 0, "params": {} }

An edge into it ends at "targetPort": "in"; one out of it starts at "sourcePort": "out".

Inputs​

PortTypeTakes
intableone edge
masktableone edge

Parameters​

ParameterKindDefaultChoices
keepmenu"inside"inside, outside

Outputs​

PortType
outtable

Details​

Older projects​

Projects saved before documents used operator classes. These convert to clip when they open: ClipOp, DifferenceOp, IntersectOp.