A collection of primitives. This is most often used with Scene#primitives,
but PrimitiveCollection is also a primitive itself so collections can
be added to collections forming a hierarchy.
alias PrimitiveCollection
- The options object takes the following properties
- {Boolean} [options.show=true] Determines if the primitives in the collection will be shown.
- {Boolean} [options.destroyPrimitives=true] Determines if primitives in the collection are destroyed when they are removed.
var billboards = new Cesium.BillboardCollection();
var labels = new Cesium.LabelCollection();
var collection = new Cesium.PrimitiveCollection();
collection.add(billboards);
scene.primitives.add(collection); // Add collection
scene.primitives.add(labels); // Add regular primitive
A collection of primitives. This is most often used with Scene#primitives, but
PrimitiveCollection
is also a primitive itself so collections can be added to collections forming a hierarchy.alias PrimitiveCollection
- The options object takes the following properties - {Boolean} [options.show=true] Determines if the primitives in the collection will be shown. - {Boolean} [options.destroyPrimitives=true] Determines if primitives in the collection are destroyed when they are removed.
var billboards = new Cesium.BillboardCollection(); var labels = new Cesium.LabelCollection(); var collection = new Cesium.PrimitiveCollection(); collection.add(billboards); scene.primitives.add(collection); // Add collection scene.primitives.add(labels); // Add regular primitive