|
|
@@ -127,25 +127,25 @@ const handlerDrawing = function (PolyType, tooltipNum) { //(传入操作的Dra
|
|
|
// that.regions.push(that.regions[0]);
|
|
|
|
|
|
viewer.entities.removeAll();
|
|
|
- let polygonEntity = new Cesium.Entity({
|
|
|
- id: "polygon",
|
|
|
- // position: Cesium.Cartesian3.fromDegreesArray([
|
|
|
- // centerX,
|
|
|
- // centerY,
|
|
|
- // ]),
|
|
|
- // classificationType: ClassificationType.TERRAIN,
|
|
|
- polygon: {
|
|
|
- hierarchy: new Cesium.PolygonHierarchy(
|
|
|
- new Cesium.Cartesian3.fromDegreesArray(nPositions)
|
|
|
- ),
|
|
|
- // positions: new Cesium.Cartesian3.fromDegreesArray(positions),
|
|
|
- material: Cesium.Color.WHITE.withAlpha(0.3),
|
|
|
- outline: true,
|
|
|
- outlineColor: Cesium.Color.RED,
|
|
|
- outlineWidth: 4,
|
|
|
- },
|
|
|
- });
|
|
|
- viewer.entities.add(polygonEntity);
|
|
|
+ // let polygonEntity = new Cesium.Entity({
|
|
|
+ // id: "polygon",
|
|
|
+ // // position: Cesium.Cartesian3.fromDegreesArray([
|
|
|
+ // // centerX,
|
|
|
+ // // centerY,
|
|
|
+ // // ]),
|
|
|
+ // // classificationType: ClassificationType.TERRAIN,
|
|
|
+ // polygon: {
|
|
|
+ // hierarchy: new Cesium.PolygonHierarchy(
|
|
|
+ // new Cesium.Cartesian3.fromDegreesArray(nPositions)
|
|
|
+ // ),
|
|
|
+ // // positions: new Cesium.Cartesian3.fromDegreesArray(positions),
|
|
|
+ // material: Cesium.Color.WHITE.withAlpha(0.3),
|
|
|
+ // outline: true,
|
|
|
+ // outlineColor: Cesium.Color.RED,
|
|
|
+ // outlineWidth: 4,
|
|
|
+ // },
|
|
|
+ // });
|
|
|
+ // viewer.entities.add(polygonEntity);
|
|
|
}
|
|
|
let positions = cartographic(result.object.positions)
|
|
|
tooltip.setVisible(false);
|