viewer.entities.add({
polyline: {
positions: Cesium.Cartesian3.fromDegreesArray(coordinateLineFromDegreesArray),
shape: [new Cesium.Cartesian2(-5, -5),
new Cesium.Cartesian2(5, -5),
new Cesium.Cartesian2(5, 5),
new Cesium.Cartesian2(-5, 5)],
cornerType: Cesium.CornerType.BEVELED,
material: Cesium.Color.GREEN.withAlpha(0.5),
outline: true,
outlineColor: Cesium.Color.BLACK,
},
parent: PipesEntity,
});
用上面的方法添加entity线,如何设置贴地形。