Backface bug in vtkActor

I’m using VTK 9.1.0 on a Linux Redhat system.

I obtain a vtkPolyDataMapper representation of a simple sphere which I use to set up a vtkActor. I’ve assigned the color red to the actor. When I assign a different color (gold) to the “back faces” of the actor using the SetBackfaceProperty function, the outside of the sphere ends up with this color and not the inside. The inside is red when I slice through the sphere. However, if I don’t assign the back face color but set back face culling on using the BackFaceCullingOn function and then slice through the sphere, the inside is not visible because of the culling – as I expect it – and the outside is still red.

So, this has to be a bug. How can in one instance the outside of the sphere contain back faces while in another it is the inside?


Some pertinent code:

vtkNew< vtkActor > zActor1;
zActor1->GetProperty()->SetColor(1.0, 0.0, 0.0)

vtkNew< vtkProperty > backFaces;
backFaces->SetDiffuseColor(colors->GetColor3d(“Gold”).GetData());

// ------------------------------------------------------------------------
// Assign the back face color or do culling, but not both.
zActor1->SetBackfaceProperty(backFaces);

//zActor1->GetProperty()->BackfaceCullingOn();

zActor1->SetMapper( zMapper );