Render Cell Scalars from vtkXMLPolyData?

The code for the actor was in the block above, but I’ll reproduce it here:

    a = vtkActor()
    a.SetMapper(m)
    a.RotateX(-20)
    a.RotateY(50)

    ren = vtkRenderer()
    ren.AddActor(a)
    renWin = vtkRenderWindow()
    renWin.AddRenderer(ren)

    iren = vtkRenderWindowInteractor()
    iren.SetRenderWindow(renWin)
    style = vtkInteractorStyleTrackballCamera()
    iren.SetInteractorStyle(style)

    renWin.SetSize(300, 300)
    renWin.SetWindowName("Solid Body")
    iren.Initialize()
    ren.ResetCamera()
    renWin.Render()
    iren.Start()

The code for reading the file also reproduced:

    r = vtkXMLPolyDataReader()
    r.SetFileName(fname)
    r.Update()

I’ll see if I can find a suitable XML file to share, but the one I am working on now is customer’s data, and I’m not sure I can share. However, it does show up fine in ParaView.