Why is it that the below Polyline Primitive cannot be picked despite having allowPicking set to true?
Sandcastle example (link to sandcastle):
var viewer = new Cesium.Viewer(‘cesiumContainer’);
var scene = viewer.scene;
var primitive = new Cesium.Primitive({
geometryInstances: new Cesium.GeometryInstance({
geometry: new Cesium.PolylineGeometry({
positions: Cesium.Cartesian3.fromDegreesArrayHeights([-75, 43, 500000,
-125, 43, 500000]),
width: 2.0,
followSurface: false,
colors: [{red:1,green:0,blue:0}, {red:0,green:1,blue:1}],
colorsPerVertex: true,
vertexFormat: Cesium.PolylineColorAppearance.VERTEX_FORMAT
}),
id: ‘T01’,
attributes: {
show: new Cesium.ShowGeometryInstanceAttribute(true)
}
}),
allowPicking: true,
appearance: new Cesium.PolylineColorAppearance({
translucent: false
})
});
scene.primitives.add(primitive);
viewer.zoomTo(viewer.entities);
``
I have to use the Primitive to get the color gradient vs the Polyline Entity which doesn’t allow that. Is there a parameter I’m missing that’s required to allow it to be picked?