使用CircleOutlineGeometry绘制了一个圆的轮廓,然后想设置轮廓的颜色,设置了appearance没有生效,但是给CircleGeometry就生效了,以下是我的代码,老师能帮忙看下哪里写的有问题吗?
var circleOutline = new Cesium.CircleOutlineGeometry({
center : Cesium.Cartesian3.fromDegrees(116.45165939834018,39.90142089948198),
radius : 100.0,
height:10
});
var circleInstance = new Cesium.GeometryInstance({
geometry:circleOutline ,
attributes : {
color : Cesium.ColorGeometryInstanceAttribute.fromColor(
Cesium.Color.fromCssColorString("rgba(0,214,240, 0.5)"))
},
});
var primitive = new Cesium.Primitive({
geometryInstances : circleInstance,
appearance : new Cesium.PerInstanceColorAppearance({
translucent : true,
closed : true
})
});
viewer.scene.primitives.add(primitive);