pgsplit

From STX Wiki
Jump to navigationJump to search

Use a line to split a polygon into two parts.

Usage
pgsplit(X, IX, PX1scalar, PY1scalar), PX2scalar, PY2scalar)
X
a closed point-list or a polygon-stream defining one or more polygons.
IX
The index of the polygon of X to be splitted; 0 ≤ IX < pgget(X)
PX1, PY1, PX2, PY2
The points <PX1,PY1> and <PX2,PY2> defining the line to split the polygon. There must be exactly two intersections of the line with the polygon!
Result
The result r is a polygon-stream containing the two split parts of the polygon.
See also
pginit, pgget, pgitest, pgiline, pgxgrid, pgtrans, pghull

<function list>

Navigation menu

Personal tools