new GroundPolylineGeometry(options)
A description of a polyline on terrain or 3D Tiles. Only to be used with GroundPolylinePrimitive.
| Name | Type | Description | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object |
Options with the following properties:
|
Throws:
-
At least two positions are required.
- Type
- DeveloperError
Example
var positions = SuperMap3D.Cartesian3.fromDegreesArray([
-112.1340164450331, 36.05494287836128,
-112.08821010582645, 36.097804071380715,
-112.13296079730024, 36.168769146801104
]);
var geometry = new SuperMap3D.GroundPolylineGeometry({
positions : positions
});
Members
-
arcTypeArcType
-
The type of path the polyline must follow. Valid options are
ArcType.GEODESICandArcType.RHUMB.- Default Value: ArcType.GEODESIC
granularityBoolean
The distance interval used for interpolating options.points. Zero indicates no interpolation. Default of 9999.0 allows centimeter accuracy with 32 bit floating point.
- Default Value: 9999.0
loopBoolean
Whether during geometry creation a line segment will be added between the last and first line positions to make this Polyline a loop. If the geometry has two positions this parameter will be ignored.
- Default Value: false
widthNumber
The screen space width in pixels.
Methods
-
static pack(value, array, startingIndex){Array.<Number>}
-
Stores the provided instance into the provided array.
Name Type Default Description valuePolygonGeometry The value to pack.
arrayArray.<Number> The array to pack into.
startingIndexNumber 0 可选 The index into the array at which to start packing the elements.
Returns:
Type Description Array.<Number> The array that was packed into -
static unpack(array, startingIndex, result)
-
Retrieves an instance from a packed array.
Name Type Default Description arrayArray.<Number> The packed array.
startingIndexNumber 0 可选 The starting index of the element to be unpacked.
resultPolygonGeometry 可选 The object into which to store the result.