PolylineGraphics

new Cesium.PolylineGraphics(options)

Describes a polyline. The first two positions define a line segment, and each additional position defines a line segment from the previous position. The segments can be linear connected points, great arcs, or clamped to terrain.
参数名称 类型 描述信息
options PolylineGraphics.ConstructorOptions 可选 Object describing initialization options
Demo:
参考:

成员(属性)

Gets or sets the ArcType Property specifying whether the line segments should be great arcs, rhumb lines or linearly connected.
默认值: ArcType.GEODESIC
Gets or sets the boolean Property specifying whether the polyline should be clamped to the ground.
默认值: false
Gets or sets the ClassificationType Property specifying whether this polyline will classify terrain, 3D Tiles, or both when on the ground.
默认值: ClassificationType.BOTH
Gets the event that is raised whenever a property or sub-property is changed or modified.
Gets or sets the Property specifying the material used to draw the polyline when it fails the depth test.

Requires the EXT_frag_depth WebGL extension to render properly. If the extension is not supported, there may be artifacts.

默认值: undefined

distanceDisplayCondition : Property|undefined

Gets or sets the DistanceDisplayCondition Property specifying at what distance from the camera that this polyline will be displayed.
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.
默认值: Cesium.Math.RADIANS_PER_DEGREE
Gets or sets the Property specifying the material used to draw the polyline.
默认值: Color.WHITE
Gets or sets the Property specifying the array of Cartesian3 positions that define the line strip.
Get or sets the enum Property specifying whether the polyline casts or receives shadows from light sources.
默认值: ShadowMode.DISABLED
Gets or sets the boolean Property specifying the visibility of the polyline.
默认值: true
Gets or sets the numeric Property specifying the width in pixels.
默认值: 1.0
Gets or sets the zIndex Property specifying the ordering of the polyline. Only has an effect if `clampToGround` is true and polylines on terrain is supported.
默认值: 0

方法

Duplicates this instance.
参数名称 类型 描述信息
result PolylineGraphics 可选 The object onto which to store the result.
返回值:
The modified result parameter or a new instance if one was not provided.
Assigns each unassigned property on this object to the value of the same property on the provided source object.
参数名称 类型 描述信息
source PolylineGraphics The object to be merged into this object.

定义的类型

Cesium.PolylineGraphics.ConstructorOptions

Initialization options for the PolylineGraphics constructor
属性:
属性名称 类型 可选 默认值 描述信息
show Property | boolean <可选>
true A boolean Property specifying the visibility of the polyline.
positions Property | Array.<Cartesian3> <可选>
A Property specifying the array of Cartesian3 positions that define the line strip.
width Property | number <可选>
1.0 A numeric Property specifying the width in pixels.
granularity Property | number <可选>
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 <可选>
Color.WHITE A Property specifying the material used to draw the polyline.
depthFailMaterial MaterialProperty | Color <可选>
A property specifying the material used to draw the polyline when it is below the terrain.
arcType Property | ArcType <可选>
ArcType.GEODESIC The type of line the polyline segments must follow.
clampToGround Property | boolean <可选>
false A boolean Property specifying whether the Polyline should be clamped to the ground.
shadows Property | ShadowMode <可选>
ShadowMode.DISABLED An enum Property specifying whether the polyline casts or receives shadows from light sources.
distanceDisplayCondition Property | DistanceDisplayCondition <可选>
A Property specifying at what distance from the camera that this polyline will be displayed.
classificationType Property | ClassificationType <可选>
ClassificationType.BOTH An enum Property specifying whether this polyline will classify terrain, 3D Tiles, or both when on the ground.
zIndex Property | number <可选>
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.