GeoImageCircleEffectLayer

new Cesium.GeoImageCircleEffectLayer(options)

吉奥图像圆圈特效图层类
Name Type Description
options Object optional 参数选项:
Name Type Description
effectType Viewer optional 特效类型,值可以为"DynamicCircle", "RadarScan","ImageCircle"之一
effectTypeMapField Viewer optional 特效类型映射字段
color Viewer optional 颜色值
colorMapField Viewer optional 颜色值由指定字段值决定
sectorColor Viewer optional 雷达扫描的扇面颜色
sectorColorMapField Viewer optional 雷达扫描的扇面颜色由指定字段值决定
lineColor Viewer optional 边框颜色
lineColorMapField Viewer optional 边框颜色由指定字段值决定
lineWidth Number optional 边框宽度
lineWidthMapField Number optional 边框宽度由指定字段值决定
radius Viewer optional 半径
radiusMapField Viewer optional 半径由指定字段值决定
height Array optional 高度
url Array optional 贴图路径
Author:
  • zj
Example:
//贴图圆圈特效图层
effectLayer1 = new Cesium.GeoImageCircleEffectLayer({
	effectType: "ImageCircle",
	url: "/geomap-api/JsCesuimDemo/resource/images/circular.png",
	radius: 2000.0,
	color: Cesium.Color.WHITE
});
effectLayer1.addTo(viewer);
effectLayer1.setData([
	{
		"type": "Feature",
		"properties": {
			"name": "imageCircle1",
			"radius":2000.0
		}, 
		"geometry": {
			"type": "Point",
			"coordinates": [121.498604, 31.240103, 0]
		}
	}
]);


//雷达扫描特效图层
effectLayer2 = new Cesium.GeoImageCircleEffectLayer({
	effectType: "RadarScan",
	height: 0,
	lineColor: Cesium.Color.BLUE,
	lineWidth: 20,
	sectorColor: Cesium.Color.BLUE,
	radius: 1500
});
effectLayer2.addTo(viewer);
effectLayer2.setData([
	{
		"type": "Feature",
		"properties": {
			"name": "RadarScan1",
			"scanRingRadius":2000.0
		}, 
		"geometry": {
			"type": "Point",
			"coordinates": [121.498604, 31.240103, 0]
		}
	}
]);

//动态圆圈特效图层
effectLayer3 = new Cesium.GeoImageCircleEffectLayer({
	effectType: "DynamicCircle",
	height: 0,
	radius: 1000.0,                    
	color: Cesium.Color.CYAN
});                
effectLayer3.addTo(viewer);
effectLayer3.setData([
	{
		"type": "Feature",
		"properties": {
			"name": "dynamicCircle1",
			"scanRingRadius":2000.0
		}, 
		"geometry": {
			"type": "Point",
			"coordinates": [121.498604, 31.240103, 0]
		}
	}
]);
Demo:

Extends

Methods

addTo(map)

绑定到三维地图
Name Type Description
map viewer
Inherited From:

destroy()

销毁图层对象
Inherited From:

getData()

获取图层数据
Inherited From:

getDataSource()

获取数据源
Inherited From:

hide()

隐藏图层

pickFeatures(pickedFeatures, windowPosition)Object

拾取图层中的要素
Name Type Description
pickedFeatures Array 场景中被拾取的对象集合,需要在图层自己内部判断识别出属于自己的,并挂接上图层的属性信息
windowPosition Cartesian2 画布的二维坐标
Returns:
返回固定形态的结构数据
Example:
//返回结构参考样例
{
			eventType: ScreenSpaceEventType.LEFT_CLICK,
			originalLayer: GeoWaterEffectLayer
			param:{
				info: pickedFeature,
				pickedInfos: pickedFeatureList
			}
		}

remove()

将图层从视图移除

removeDataSource()

移除数据源
Inherited From:

setData(features)

设置图层相关数据
Name Type Description
features Array.<Object> geojson要素数组,本类只支持Point几何对象类型
Example:
effectLayer.setData([
	{
		"type": "Feature",
		"properties": {
			"name": "imageCircle1",
			"radius":2000.0
		}, 
		"geometry": {
			"type": "Point",
			"coordinates": [121.498604, 31.240103, 0]
		}
	}
]);

setDataSource(dataSource)

设置数据源
Name Type Description
dataSource GeoDataSource
Inherited From:

show()

显示图层