Returns the number of polylines in this collection. This is commonly used with {@link PolylineCollection#get} to iterate over all the polylines in the collection.
The 4x4 transformation matrix that transforms each polyline in this collection from model to world coordinates. When this is the identity matrix, the polylines are drawn in world coordinates, i.e., Earth's WGS84 coordinates. Local reference frames can be used by providing a different transformation matrix, like that returned by {@link Transforms.eastNorthUpToFixedFrame}.
Creates and adds a polyline with the specified initial properties to the collection. The added polyline is returned so it can be modified or removed from the collection later.
The polyline that was added to the collection.
Determines if this collection contains the specified polyline.
The polyline to check for.
true if this collection contains the polyline, false otherwise.
Destroys the WebGL resources held by this object. Destroying an object allows for deterministic
release of WebGL resources, instead of relying on the garbage collector to destroy this object.
Once an object is destroyed, it should not be used; calling any function other than
isDestroyed
will result in a DeveloperError exception. Therefore,
assign the return value (undefined
) to the object as done in the example.
Returns the polyline in the collection at the specified index. Indices are zero-based and increase as polylines are added. Removing a polyline shifts all polylines after it to the left, changing their indices. This function is commonly used with {@link PolylineCollection#length} to iterate over all the polylines in the collection.
The zero-based index of the polyline.
The polyline at the specified index.
Returns true if this object was destroyed; otherwise, false.
If this object was destroyed, it should not be used; calling any function other than
isDestroyed
will result in a DeveloperError exception.
true
if this object was destroyed; otherwise, false
.
Removes a polyline from the collection.
The polyline to remove.
true
if the polyline was removed; false
if the polyline was not found in the collection.
Removes all polylines from the collection.
Called when Viewer or {@link CesiumWidget} render the scene to get the draw commands needed to render this primitive.
Do not call this function directly. This is documented just to list the exceptions that may be propagated when the scene is rendered:
This property is for debugging only; it is not for production use nor is it optimized.
Draws the bounding sphere for each draw command in the primitive.