Constructor
new ContourLine(viewer, optionsopt)
Parameters:
Name | Type | Attributes | Description | ||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
viewer |
Viewer | 要分析的场景对象 |
|||||||||||||||||||||||||||||||||||||||||||||||||||
options |
Object |
<optional> |
带有以下属性的对象: Properties
|
Methods
clear()
清空数据
destroy()
销毁对象
enableContour(bShowContour)
设置是否显示等高线
Parameters:
Name | Type | Description |
---|---|---|
bShowContour |
Boolean | 是否显示等高线 |
setContourColor(cssColor)
设置等高线颜色
Parameters:
Name | Type | Description |
---|---|---|
cssColor |
String | css格式的颜色,例如"#ff0000" |
setContourSpacing(spacing)
设置等高线间隔
Parameters:
Name | Type | Description |
---|---|---|
spacing |
Number | 等高线间隔 |
setContourWidth(width)
设置等高线宽度
Parameters:
Name | Type | Description |
---|---|---|
width |
Number | 高线宽度 |
setSelectedShading(selectedShading)
设置地形渲染类型
Parameters:
Name | Type | Description |
---|---|---|
selectedShading |
'elevation' | 'slope' | 'none' |