Home > other >  The problems in the python visualization, using ivtk observation of pipeline failure
The problems in the python visualization, using ivtk observation of pipeline failure

Time:01-26

 the from TVTK. API import TVTK 
The from TVTK. Tools import ivtk
The from pyface. API import GUI

# visualization pipeline section
S=TVTK. CubeSource (x_length=1.0, y_length=2.0, z_length=3.0)
(m=TVTK PolyDataMapper input_connection=s.o utput_port)
# graphics pipeline section
A=TVTK. Actor (mapper=m) # to create an entity

# to create a Crust with the window (Python Shell)
GUI GUI ()=
Win=ivtk. IVTKWithCrustAndBrowser ()
Win. The open ()
Win. Scene. Add_actor (a)

# error corrections
Dialog=win. Control. CentralWidget (). The widget (0). The widget (0)
The from pyface. Qt import QtCore
Dialog. SetWindowFlags (QtCore. Qt. WindowFlags (0 x00000000))
Dialog. The show ()

# open interface message loop
GUI. Start_event_loop ()


Learning python visualization in the mooc preliminary debugging through, when using ivtk observation line can't run,
The following mistakes always import a name 'PythonShell'
 ImportError: always import the name 'PythonShell 


Is there a big can help me answer the question? Thank you very much!
  • Related