1. A concise explanation of the problem you're experiencing.
Polygon outline geometry not clipping to terrain
2. A minimal code example. If you've found a bug, this helps us reproduce and repair it.
this._outlinePolygon = new Cesium.Primitive({
geometryInstances: new Cesium.GeometryInstance({
geometry: Cesium.PolygonOutlineGeometry.fromPositions({
positions: this.getPositions()
}),
attributes: {
color: Cesium.ColorGeometryInstanceAttribute.fromColor(this.strokeColor)
}
}),
appearance: new Cesium.PerInstanceColorAppearance({
flat: true,
renderState: {
depthTest: {
enabled: true
},
lineWidth: Math.min(this.strokeWidth || 1.0, maximumAliasedLineWidth)
}
})
});
3. Context. Why do you need to do this? We might know a better way to accomplish your goal.
4. The Cesium version you're using, your operating system and browser.
1.56.1