[vtkusers] imageMapper doesn't work

francesco caruso guernika_devel at yahoo.it
Tue Sep 28 04:26:48 EDT 2004


hi
can you tell me why this code doesn't work, while if I set
imageActor as a vtkActor(instead of a vtkActor2D) and imageMapper as a 
DataSetMapper, it works?


  imageMapper = vtk.vtkImageMapper()
  imageMapper.SetInput( imageData )#previously defined

  imageActor = vtk.vtkActor2D()
  imageActor.SetMapper( imageMapper )

  win = vtk.vtkRenderWindow()
  win.SetSize(640,480)

  ren = vtk.vtkRenderer()
  ren.AddProp( imageActor )#image goes in the transparent layer!!!

  win.AddRenderer( ren )

  win.Render()
  sleep(1)	




More information about the vtkusers mailing list