Programmer Guide/Command Reference/EVAL/pgget: Difference between revisions
From STX Wiki
< Programmer Guide | Command Reference | EVAL
Jump to navigationJump to search
No edit summary |
No edit summary |
||
Line 18: | Line 18: | ||
---- | ---- | ||
;See also: [[../pginit|pginit]], [[../pgitest|pgitest]], [[../pgiline|pgiline]], [[../pgxgrid|pgxgrid]], [[../pgsplit|pgsplit]], [[../pgtrans|pgtrans]], [[../pghull|pghull]] | ;See also: [[../pginit|pginit]], [[../pgitest|pgitest]], [[../pgiline|pgiline]], [[../pgxgrid|pgxgrid]], [[../pgsplit|pgsplit]], [[../pgtrans|pgtrans]], [[../pghull|pghull]] | ||
[[../#Functions|<function list>]] | [[../#Functions|<function list>]] |
Revision as of 11:29, 21 April 2011
Extract a polygon from a closed point-list or a polygon-stream.
- Usage 1
pgget(X)
- X
- A closed point-list or a polygon-stream defining one or more polygons.
- Result 1
- The number of simple polygons N stored in X. If the result is 0, X contains no valid polygons.
- Usage 2
pgget(X, I, fmt)
- X
- A closed point-list or a polygon-stream defining one or more polygons.
- I
- The index of the polygon to be returned; 0 <= I < N (=
pgget(X)
) - fmt
- The format of the result.:
fmt=0 ... return the I-th polygon of X as polygon-stream fmt=1 ... return the polygon-stream header (a 8x2 matrix) of the I-th polygon of X
- Result 2
- The I-th polygon stored in X in the format selected by fmt.