|
#
- Number of points in polygon
+ Number of points in path or polygon
# '((1,0),(0,1),(-1,0))'
|
length of item
length(path '((-1,0),(1,0))')
+ |
+ npoints(path)
+ integer
+ number of points
+ npoints(path '[(0,0),(1,1),(2,0)]')
+
+ |
+ npoints(polygon)
+ integer
+ number of points
+ npoints(polygon '((1,1),(0,0))')
+
|
pclose(path)
path
point(lseg '((-1,0),(1,0))',lseg '((-2,-2),(2,2))')
]]>
- |
- npoint(path)
- integer
- number of points
- npoints(path '[(0,0),(1,1),(2,0)]')
-
|
popen(path)
path
|
polygon(box)
polygon
- 12 point polygon
+ 4-point polygon
polygon(box '((0,0),(1,1))')
|
+ It is possible to access the two component numbers of a point>
+ as though it were an array with subscripts 0,1. For example, if
+ t.p> is a point> column then
+ SELECT p[0] FROM t> retrieves the X coordinate;
+ UPDATE t SET p[1] = ...> changes the Y coordinate.
+ In the same way, a box> or an lseg> may be treated
+ as an array of two point>s.
+
+