描述一个走廊,这是一种由中心线和宽度定义的形状,符合地球的曲率。
它可以放置在地面上或在某个高度,并可选择性地挤压成一个体积。
| Name | Type | Description |
|---|---|---|
options |
CorridorGraphics.ConstructorOptions | optional Object describing initialization options |
Demo:
See:
Members
classificationType : Property|undefined
获取或设置
ClassificationType 属性,指定此走廊在地面上时是否分类地形、3D Tiles 或两者。
-
Default Value:
ClassificationType.BOTH
cornerType : Property|undefined
获取或设置
CornerType 属性,指定角落的样式。
-
Default Value:
CornerType.ROUNDED
readonly definitionChanged : Event
获取每当属性或子属性更改或修改时引发的事件。
distanceDisplayCondition : Property|undefined
获取或设置
DistanceDisplayCondition 属性,指定在距相机多远时将显示此走廊。
extrudedHeight : Property|undefined
获取或设置一个数字属性,指定走廊挤压体的高度。
设置此属性会创建一个形状为走廊的体积,从高度开始,直到达到此高度。
extrudedHeightReference : Property|undefined
获取或设置属性,指定挤压的
HeightReference。
-
Default Value:
HeightReference.NONE
fill : Property|undefined
获取或设置布尔属性,指定走廊是否填充提供的材质。
-
Default Value:
true
granularity : Property|undefined
获取或设置一个数字属性,指定每个经纬度点之间的采样距离。
-
Default Value:
{CesiumMath.RADIANS_PER_DEGREE}
height : Property|undefined
获取或设置一个数字属性,指定走廊的高度。
-
Default Value:
0.0
heightReference : Property|undefined
获取或设置一个属性,指定
HeightReference。
-
Default Value:
HeightReference.NONE
material : MaterialProperty|undefined
获取或设置属性,指定用于填充走廊的材质。
-
Default Value:
Color.WHITE
outline : Property|undefined
获取或设置属性,指定走廊是否带轮廓。
-
Default Value:
false
outlineColor : Property|undefined
获取或设置属性,指定轮廓的
Color。
-
Default Value:
Color.BLACK
outlineWidth : Property|undefined
获取或设置一个数字属性,指定轮廓的宽度。
注意:此属性将在 Windows 平台上的所有主要浏览器中被忽略。有关详细信息,请参见 https://github.com/CesiumGS/cesium/issues/40。
-
Default Value:
1.0
positions : Property|undefined
获取或设置一个属性,指定定义走廊中心线的
Cartesian3 位置数组。
shadows : Property|undefined
获取或设置枚举属性,指定走廊是否投射或接收光源的阴影。
-
Default Value:
ShadowMode.DISABLED
show : Property|undefined
获取或设置布尔属性,指定走廊的可见性。
-
Default Value:
true
width : Property|undefined
获取或设置一个数字属性,指定轮廓的宽度。
zIndex : ConstantProperty|undefined
获取或设置 zIndex 属性,指定走廊的排序。只有在走廊是静态的且未指定高度或挤压高度时有效。
-
Default Value:
0
Methods
clone(result) → CorridorGraphics
复制此实例。
| Name | Type | Description |
|---|---|---|
result |
CorridorGraphics | optional 存储结果的对象。 |
Returns:
修改后的结果参数,如果未提供则返回一个新的实例。
将此对象上每个未分配的属性赋值为提供的源对象上同名属性的值。
| Name | Type | Description |
|---|---|---|
source |
CorridorGraphics | 要合并到此对象的对象。 |
Type Definitions
CorridorGraphics 构造函数的初始化选项
Properties:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
show |
Property | boolean |
<optional> |
true | 一个布尔值属性,指定走廊的可见性。 |
positions |
Property | Array.<Cartesian3> |
<optional> |
一个属性,指定定义走廊中心线的 Cartesian3 位置数组。 |
|
width |
Property | number |
<optional> |
一个数字属性,指定走廊边缘之间的距离。 | |
height |
Property | number |
<optional> |
0 | 一个数字属性,指定走廊相对于椭球表面的高度。 |
heightReference |
Property | HeightReference |
<optional> |
HeightReference.NONE | 一个属性,指定高度的参考。 |
extrudedHeight |
Property | number |
<optional> |
一个数字属性,指定走廊挤压面相对于椭球表面的高度。 | |
extrudedHeightReference |
Property | HeightReference |
<optional> |
HeightReference.NONE | 一个属性,指定挤压高度的参考。 |
cornerType |
Property | CornerType |
<optional> |
CornerType.ROUNDED | 一个 CornerType 属性,指定角落的样式。 |
granularity |
Property | number |
<optional> |
Cesium.Math.RADIANS_PER_DEGREE | 一个数字属性,指定每个经纬度之间的距离。 |
fill |
Property | boolean |
<optional> |
true | 一个布尔值属性,指定走廊是否填充提供的材质。 |
material |
MaterialProperty | Color |
<optional> |
Color.WHITE | 一个属性,指定填充走廊的材质。 |
outline |
Property | boolean |
<optional> |
false | 一个布尔值属性,指定走廊是否带轮廓。 |
outlineColor |
Property | Color |
<optional> |
Color.BLACK | 一个属性,指定轮廓的 Color。 |
outlineWidth |
Property | number |
<optional> |
1.0 | 一个数字属性,指定轮廓的宽度。 |
shadows |
Property | ShadowMode |
<optional> |
ShadowMode.DISABLED | 一个枚举属性,指定走廊是否投射或接收光源的阴影。 |
distanceDisplayCondition |
Property | DistanceDisplayCondition |
<optional> |
一个属性,指定这条走廊在距离相机多远时将被显示。 | |
classificationType |
Property | ClassificationType |
<optional> |
ClassificationType.BOTH | 一个枚举属性,指定当在地面上时此走廊将分类地形、3D Tiles 还是两者。 |
zIndex |
ConstantProperty | number |
<optional> |
一个属性,指定走廊的 zIndex,用于排序。仅在高度和挤压高度未定义,并且走廊为静态时生效。 |
