add

fun add(options: Any? = definedExternally): CumulusCloud(source)

Creates and adds a cloud with the specified initial properties to the collection. The added cloud is returned so it can be modified or removed from the collection later.

// Example 1:  Add a cumulus cloud, specifying all the default values.
const c = clouds.add({
show : true,
position : Cartesian3.ZERO,
scale : new Cartesian2(20.0, 12.0),
maximumSize: new Cartesian3(20.0, 12.0, 12.0),
slice: -1.0,
cloudType : CloudType.CUMULUS
});
// Example 2:  Specify only the cloud's cartographic position.
const c = clouds.add({
position : Cartesian3.fromDegrees(longitude, latitude, height)
});

Return

The cloud that was added to the collection.

Parameters

options

A template describing the cloud's properties as shown in Example 1.

See also