I am am writing a web app builder widget, and i want to re-render a scenelayer coming from my sceneview. I set the renderer on the scenelayer, but nothing happens. Any ideas?
see the code below.
public startup() {
this.sceneView.map.allLayers.forEach((layer: Layer) => {
if (layer.id == "154bd77e20e-layer-16") {
this.layerToRender = layer as SceneLayer;
}
});
   var symbol = new MeshSymbol3D(
       new FillSymbol3DLayer({
          material: {
             color: [244, 2, 1]
          }
       })
    );
   var renderer = new SimpleRenderer({
       symbol: symbol
    });
this.layerToRender.renderer = renderer;
}
Hi James,
could you post a snippet with your code? That way it's easier to debug...
But on a first glance looks like you're passing a symbol layer directly to the constructor of the symbol. You should pass it to the symbolLayers property, like this:
symbol: new MeshSymbol3D({
   symbolLayers: [
      new FillSymbol3DLayer({
        material: {
           color: "#ffffff"
        }
     })
   ]
})