BufferPolyline

View bound to the underlying buffer data of a BufferPolylineCollection.

BufferPolyline instances are flyweights: a single BufferPolyline instance can be temporarily bound to any conceptual "polyline" in a BufferPolylineCollection, allowing very large collections to be iterated and updated with a minimal memory footprint.

Represented as two (2) or more positions.

new Cesium.BufferPolyline()

Experimental

This feature is not final and is subject to change without Cesium's standard deprecation policy.

See:

Extends

Members

Feature ID associated with the primitive; not required to be unique.
Inherited From:
Whether primitive is shown.
Inherited From:

readonly vertexCount : number

Count of positions (vertices) in this polyline, number of VEC3 elements.
Width of polyline, 0–255px.

Methods

static Cesium.BufferPolyline.clone(polyline, result)BufferPolyline

Copies data from source polyline to result. If the result polyline is not new (the last polyline in the collection) then source and result polylines must have the same vertex counts.
Name Type Description
polyline BufferPolyline
result BufferPolyline
Returns:
Returns the color of primitive.
Name Type Description
result Color
Returns:
Inherited From:
Returns an array view of this polyline's vertex positions. If 'result' argument is given, vertex positions are written to that array and returned. Otherwise, returns an ArrayView on collection memory — changes to this array will not trigger render updates, which requires `.setPositions()`.
Name Type Description
result TypedArray optional return {TypedArray}
Updates the color of primitive.
Name Type Description
color Color
Inherited From:
Name Type Description
positions TypedArray
Returns a JSON-serializable object representing the polyline. This encoding is not memory-efficient, and should generally be used for debugging and testing.
Returns:
JSON-serializable object.
Inherited From:
Need help? The fastest way to get answers is from the community and team on the Cesium Forum.