描述一个多线。 前两个位置确定一个线段,
和每个附加位置定义了上一个位置的线段。 部分
可以是线性连接点,大弧,也可以夹在地形上.
| Name | Type | Description |
|---|---|---|
options |
PolylineGraphics.ConstructorOptions | optional 描述初始化选项的对象 |
Demo:
See:
Members
arcType : Property|undefined
Gets or sets the
ArcType Property specifying whether the line segments should be great arcs, rhumb lines or linearly connected.
-
Default Value:
ArcType.GEODESIC
clampToGround : Property|undefined
获取或设置布尔属性,指定复线是否
应夹在地上.
-
Default Value:
false
classificationType : Property|undefined
Gets or sets the
ClassificationType Property specifying whether this polyline will classify terrain, 3D Tiles, or both when on the ground.
-
Default Value:
ClassificationType.BOTH
readonly definitionChanged : Event
当财产或次级财产被改变或修改时,获取该事件.
depthFailMaterial : MaterialProperty
获取或设置属性,指定在未进行深度测试时绘制多线的材料.
需要 EXT frag 深度 WebGL 扩展以正确渲染 。 如果不支持扩展, 可能还有文物.
-
Default Value:
undefined
distanceDisplayCondition : Property|undefined
Gets or sets the
DistanceDisplayCondition Property specifying at what distance from the camera that this polyline will be displayed.
granularity : Property|undefined
Gets or sets the numeric Property specifying the angular distance between each latitude and longitude if arcType is not ArcType.NONE and clampToGround is false.
-
Default Value:
——NT++++++++++++++++++++++++++++++++++++++++++++++++
material : MaterialProperty
获取或设置指定用于绘制多线的属性.
-
Default Value:
Color.WHITE
positions : Property|undefined
Gets or sets the Property specifying the array of
Cartesian3
定义线条的位置.
shadows : Property|undefined
获取或设置 enum 属性, 指定复线是否
投影或接收来自光源的阴影.
-
Default Value:
ShadowMode.DISABLED
show : Property|undefined
获取或设置指定多线的可见度的布尔属性.
-
Default Value:
true
width : Property|undefined
获取或设置以像素表示宽度的数值属性.
-
Default Value:
1.0
zIndex : ConstantProperty|undefined
获取或设置指定多线顺序的 zIndex 属性 。 只有在 `clampToGround` 为真且支持地形上的多线时才有效果.
-
Default Value:
0
Methods
clone(result) → PolylineGraphics
重复这个例子.
| Name | Type | Description |
|---|---|---|
result |
PolylineGraphics | optional 存储结果的对象 . |
Returns:
未提供修改的结果参数或新实例 .
指定该对象上每个未指定属性的值
- 提供源对象上的同一财产.
| Name | Type | Description |
|---|---|---|
source |
PolylineGraphics | 要合并成此天体的对象. |
Type Definitions
PolylineGraphics 构建器的初始化选项
Properties:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
show |
Property | boolean |
<optional> |
true | 指定多线的可见度的布尔属性. |
positions |
Property | Array.<Cartesian3> |
<optional> |
A Property specifying the array of Cartesian3 positions that define the line strip. |
|
width |
Property | number |
<optional> |
1.0 | 一个数字属性,以像素表示宽度. |
granularity |
Property | number |
<optional> |
Cesium.Math.RADIANS_PER_DEGREE | A numeric Property specifying the angular distance between each latitude and longitude if arcType is not ArcType.NONE. |
material |
MaterialProperty | Color |
<optional> |
Color.WHITE | A Property specifying the material used to draw the polyline. |
depthFailMaterial |
MaterialProperty | Color |
<optional> |
指定在地形以下绘制多线材料的属性. | |
arcType |
Property | ArcType |
<optional> |
ArcType.GEODESIC | The type of line the polyline segments must follow. |
clampToGround |
Property | boolean |
<optional> |
false | A boolean Property specifying whether the Polyline should be clamped to the ground. |
shadows |
Property | ShadowMode |
<optional> |
ShadowMode.DISABLED | An enum Property specifying whether the polyline casts or receives shadows from light sources. |
distanceDisplayCondition |
Property | DistanceDisplayCondition |
<optional> |
指定显示此多线的相机距离的属性 . | |
classificationType |
Property | ClassificationType |
<optional> |
ClassificationType.BOTH | An enum Property specifying whether this polyline will classify terrain, 3D Tiles, or both when on the ground. |
zIndex |
Property | number |
<optional> |
0 | A Property specifying the zIndex used for ordering ground geometry. Only has an effect if `clampToGround` is true and polylines on terrain is supported. |