本文整理匯總了TypeScript中@turf/helpers.multiPoint函數的典型用法代碼示例。如果您正苦於以下問題:TypeScript multiPoint函數的具體用法?TypeScript multiPoint怎麽用?TypeScript multiPoint使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了multiPoint函數的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: multiPoint
import {multiPoint} from '@turf/helpers'
import * as cleanCoords from './'
// Fixtures
const multiPt = multiPoint([[0, 0], [0, 0], [2, 2]])
// Feature
cleanCoords(multiPt).geometry
cleanCoords(multiPt).properties
// Geometry
cleanCoords(multiPt.geometry).coordinates
cleanCoords(multiPt.geometry).type
// Input mutation
cleanCoords(multiPt.geometry, true)
示例2: point
} from '@turf/helpers'
import buffer from './'
// Standard Geometry
const pt = point([100, 0]);
const line = lineString([[100, 0], [50, 0]]);
const poly = polygon([[[100, 0], [50, 0], [0, 50], [100, 0]]]);
buffer(pt, 5);
buffer(line, 5);
buffer(poly, 5);
buffer(pt, 5, {units: 'miles'});
buffer(pt, 10, {units: 'meters', steps: 64});
// Multi Geometry
const multiPt = multiPoint([[100, 0], [0, 100]]);
const multiLine = multiLineString([[[100, 0], [50, 0]], [[100, 0], [50, 0]]]);
const multiPoly = multiPolygon([[[[100, 0], [50, 0], [0, 50], [100, 0]]], [[[100, 0], [50, 0], [0, 50], [100, 0]]]]);
buffer(multiPt, 5);
buffer(multiLine, 5);
buffer(multiPoly, 5);
// Collections
const fc = featureCollection<Point|LineString>([pt, line]);
const gc = geometryCollection([pt.geometry, line.geometry]);
buffer(fc, 5);
buffer(gc, 5);
// Mixed Collections