[vtkusers] "Hello World" for QVTKWidget using PyQt and VTK in Python

Jothy jothybasu at gmail.com
Wed Nov 3 11:50:43 EDT 2010


If you are using python x,y you should have QVTKRenderWindowInteractor.py in

C:\Python26\Lib\site-packages\vtk\qt4

Did you select "Full" during installation of pythonx,y?

Jothy

On Wed, Nov 3, 2010 at 3:45 PM, Prathamesh Kulkarni <
prathameshmkulkarni at gmail.com> wrote:

> I am using Python2.6 which comes with Pythonxy package. So I do not build
> VTK separately. It comes with Pythonxy too. Now, in the site_packages/vtk/qt
> I cannot find QVTKWidget. Also, in my separate build of VTK (with
> VTK_WRAP_PYTHON set) I do not get QVTKWidget iniside
> bin/wrapping/python/vtk/qt. Where can I get it from?
>
> - Prathamesh
>
>
> On Wed, Nov 3, 2010 at 5:18 AM, Jothy <jothybasu at gmail.com> wrote:
>
>> Which python bundle are you using and how are importing the QVTK?
>>
>> One easiest option is to add the QVTKWidget into your working directory
>> and import.
>>
>> Jothy
>>
>> On Wed, Nov 3, 2010 at 3:45 AM, Prathamesh Kulkarni <
>> prathameshmkulkarni at gmail.com> wrote:
>>
>>> Hello all,
>>>
>>> I want to create a GUI using PyQt4 and display a vtkImage inside it. For
>>> that, I need to embed a QVTKWidget in my GUI. However, I get 'ImportError:
>>> No module named qvtk' when I do import vtk.qvtk as given in
>>> http://vtk.1045678.n5.nabble.com/about-vtk-python-bindings-and-Qt-td2841114i20.html. I am confused about how to get started with this and did not find examples
>>> demonstrating this.
>>>
>>> Please point me to the steps for writing this "hello world".
>>>
>>> Thanks,
>>> Prathamesh
>>>
>>> _______________________________________________
>>> Powered by www.kitware.com
>>>
>>> Visit other Kitware open-source projects at
>>> http://www.kitware.com/opensource/opensource.html
>>>
>>> Please keep messages on-topic and check the VTK FAQ at:
>>> http://www.vtk.org/Wiki/VTK_FAQ
>>>
>>> Follow this link to subscribe/unsubscribe:
>>> http://www.vtk.org/mailman/listinfo/vtkusers
>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20101103/67e4c4e5/attachment.htm>


More information about the vtkusers mailing list