描述一个二维墙体,定义为一条线带(line strip)以及可选的最大高度和最小高度。墙体贴合地球的曲率,可以沿着地表放置,也可以位于一定高度。
| Name | Type | Description |
|---|---|---|
options |
WallGraphics.ConstructorOptions | optional Object describing initialization options |
Demo:
See:
Members
readonly definitionChanged : Event
获取当任何属性或子属性被更改或修改时引发的事件。
distanceDisplayCondition : Property|undefined
获取或设置
DistanceDisplayCondition 属性(Property),该属性指定了从相机到该墙体在多远距离时才会显示。
fill : Property|undefined
获取或设置一个布尔属性(Property),指定墙体是否使用提供的材质进行填充。
-
Default Value:
true
granularity : Property|undefined
获取或设置一个数值属性(Property),指定墙体上各点之间的角距离。
-
Default Value:
{CesiumMath.RADIANS_PER_DEGREE}
获取或设置指定用于填充墙体的材质的属性(Property)。
-
Default Value:
Color.WHITE
maximumHeights : Property|undefined
获取或设置指定用于墙体顶部的高度数组的属性(Property),以替代每个位置的高度。如果已定义,该数组的长度必须与
Wall#positions 相同。
minimumHeights : Property|undefined
获取或设置指定用于墙体底部的高度数组的属性(Property),以替代地球表面。
If defined, the array must be the same length as
Wall#positions.
outline : Property|undefined
获取或设置指定墙体是否带轮廓的属性(Property)。
-
Default Value:
false
outlineColor : Property|undefined
获取或设置指定轮廓
Color 的属性(Property)。
-
Default Value:
Color.BLACK
outlineWidth : Property|undefined
获取或设置一个数值属性(Property),指定轮廓的宽度。
注意:在 Windows 平台上的所有主流浏览器中,此属性将被忽略。详情参见 (@link https://github.com/CesiumGS/cesium/issues/40}。
-
Default Value:
1.0
positions : Property|undefined
获取或设置指定用于定义墙体顶部的
Cartesian3 位置数组的属性(Property)。
shadows : Property|undefined
获取或设置一个枚举属性(Property),指定墙体是否投射或接收来自光源的阴影。
-
Default Value:
ShadowMode.DISABLED
show : Property|undefined
获取或设置一个布尔属性(Property),指定墙体的可见性。
-
Default Value:
true
Methods
clone(result) → WallGraphics
复制此实例。
| Name | Type | Description |
|---|---|---|
result |
WallGraphics | optional 用于存储结果的物体。 |
Returns:
修改后的 result 参数;如果未提供,则为一个新的实例。
将此对象上每个未赋值的属性设置为所提供的源对象上相同属性的值。
| Name | Type | Description |
|---|---|---|
source |
WallGraphics | 要合并到此对象中的对象。 |
Type Definitions
Initialization options for the WallGraphics constructor
Properties:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
show |
Property | boolean |
<optional> |
true | 指定墙体可见性的布尔属性(Property)。 |
positions |
Property | Array.<Cartesian3> |
<optional> |
指定用于定义墙体顶部的 Cartesian3 位置数组的属性(Property)。 |
|
minimumHeights |
Property | Array.<number> |
<optional> |
指定用于墙体底部、以替代地球表面的高度数组的属性(Property)。 | |
maximumHeights |
Property | Array.<number> |
<optional> |
指定用于墙体顶部、以替代每个位置高度的高度数组的属性(Property)。 | |
granularity |
Property | number |
<optional> |
Cesium.Math.RADIANS_PER_DEGREE | 指定每个经纬度点之间角距离的数值属性(Property)。 |
fill |
Property | boolean |
<optional> |
true | 指定墙体是否使用提供的材质进行填充的布尔属性(Property)。 |
material |
MaterialProperty | Color |
<optional> |
Color.WHITE | 指定用于填充墙体的材质的属性(Property)。 |
outline |
Property | boolean |
<optional> |
false | 指定墙体是否带轮廓的布尔属性(Property)。 |
outlineColor |
Property | Color |
<optional> |
Color.BLACK | 指定轮廓 Color 的属性(Property)。 |
outlineWidth |
Property | number |
<optional> |
1.0 | 指定轮廓宽度的数值属性(Property)。 |
shadows |
Property | ShadowMode |
<optional> |
ShadowMode.DISABLED | 指定墙体是否投射或接收来自光源的阴影的枚举属性(Property)。 |
distanceDisplayCondition |
Property | DistanceDisplayCondition |
<optional> |
指定从相机到该墙体在多远距离时才会显示的属性(Property)。 |
