new WallOutlineGeometry(options)
A description of a wall outline. A wall is defined by a series of points,
which extrude down to the ground. Optionally, they can extrude downwards to a specified height.
Parameters:
Name | Type | Description | ||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | Object with the following properties:
Properties
|
- Source:
- See:
-
- WallGeometry#createGeometry
- WallGeometry#fromConstantHeight
Throws:
-
-
positions length must be greater than or equal to 2.
- Type
- DeveloperError
-
-
-
positions and maximumHeights must have the same length.
- Type
- DeveloperError
-
-
-
positions and minimumHeights must have the same length.
- Type
- DeveloperError
-
Example
// create a wall outline that spans from ground level to 10000 meters
var wall = new Cesium.WallOutlineGeometry({
positions : Cesium.Cartesian3.fromDegreesArrayHeights([
19.0, 47.0, 10000.0,
19.0, 48.0, 10000.0,
20.0, 48.0, 10000.0,
20.0, 47.0, 10000.0,
19.0, 47.0, 10000.0
])
});
var geometry = Cesium.WallOutlineGeometry.createGeometry(wall);
Members
packedLength :Number
The number of elements used to pack the object into an array.
Type:
- Number
- Source:
Methods
(static) createGeometry(wallGeometry) → {Geometry|undefined}
Computes the geometric representation of a wall outline, including its vertices, indices, and a bounding sphere.
Parameters:
Name | Type | Description |
---|---|---|
wallGeometry |
WallOutlineGeometry | A description of the wall outline. |
- Source:
Returns:
The computed vertices and indices.
- Type
- Geometry | undefined
(static) fromConstantHeights(options) → {WallOutlineGeometry}
A description of a walloutline. A wall is defined by a series of points,
which extrude down to the ground. Optionally, they can extrude downwards to a specified height.
Parameters:
Name | Type | Description | |||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | Object with the following properties:
Properties
|
- Source:
- See:
-
- WallOutlineGeometry#createGeometry
Returns:
- Type
- WallOutlineGeometry
Example
// create a wall that spans from 10000 meters to 20000 meters
var wall = Cesium.WallOutlineGeometry.fromConstantHeights({
positions : Cesium.Cartesian3.fromDegreesArray([
19.0, 47.0,
19.0, 48.0,
20.0, 48.0,
20.0, 47.0,
19.0, 47.0,
]),
minimumHeight : 20000.0,
maximumHeight : 10000.0
});
var geometry = Cesium.WallOutlineGeometry.createGeometry(wall);
(static) pack(value, array, startingIndexopt) → {Array.<Number>}
Stores the provided instance into the provided array.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
value |
WallOutlineGeometry | The value to pack. | ||
array |
Array.<Number> | The array to pack into. | ||
startingIndex |
Number |
<optional> |
0 | The index into the array at which to start packing the elements. |
- Source:
Returns:
The array that was packed into
- Type
- Array.<Number>
(static) unpack(array, startingIndexopt, resultopt) → {WallOutlineGeometry}
Retrieves an instance from a packed array.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
array |
Array.<Number> | The packed array. | ||
startingIndex |
Number |
<optional> |
0 | The starting index of the element to be unpacked. |
result |
WallOutlineGeometry |
<optional> |
The object into which to store the result. |
- Source:
Returns:
The modified result parameter or a new WallOutlineGeometry instance if one was not provided.
- Type
- WallOutlineGeometry