I try to visualize some 3d scatter using vtkTexturedSphereSource. Everything seems well when I using RenderWindow.SetMultiSamples(12) to anti-aliasing as the users-guide commend. But when I set opacity by RenderWindow.SetMultiSamples(12), the sphere become semitransparent, and the antialiasing effect is disappeared. Second, when I add shadow for these sphere and set the opacity to less than 1, all of the sphere is vanished. I don’t know where the question is. The code to set shadow as follow:
shadows = vtk.vtkShadowMapPass()
seq = vtk.vtkSequencePass()
passes = vtk.vtkRenderPassCollection()
passes.AddItem(shadows.GetShadowMapBakerPass())
passes.AddItem(shadows)
seq.SetPasses(passes)
self.CameraPass = vtk.vtkCameraPass()
self.CameraPass.SetDelegatePass(seq)
self.Renderer.SetPass(self.CameraPass)
Thanks!
Opacity = 1:
Opacity = 0.3 and not set the shadow: