[vtkusers] urgent

Dharmendra dharmendra at strandgenomics.com
Wed Oct 16 04:28:31 EDT 2002


Hello,
    Let me make myself clear.
I have a renderwindow in python/Tkinter(
ren_widget = vtkRenderWidget.vtkTkRenderWidget( frame )
                 ren_win = ren_widget.GetRenderWindow()

Now i want to pass this ren_win to a  c++ class which adds renderers to it 
and returns ren_win.
In my python code i will say ren_win.render().

how to acheive this.
with some code example.

thanks
dharmendra



At 03:05 PM 10/15/2002 +0530, you wrote:
> >>>>> "D" == dharmendra  <dharmendra at strandgenomics.com> writes:
>
>     D> Hello All, I am new to VTK.My requirements are like this.  Gui
>     D> is going to be in Python/tkinter and visualization part is
>     D> going to be in c++.  My question is how to get a
>     D> VTKRenderWindow(which is in c++) from python.
>
>The function
>
>vtkObjectBase *vtkPythonGetPointerFromObject(PyObject *obj,
>                                              const char *result_type)
>
>is defined in Common/vtkPythonUtil.h
>
>Simply pass this function the Python object that corresponds to your
>Python vtkRenderWindow and the expected return type ("vtkRenderWindow"
>in this case) and then use the returned pointer (after suitably
>typecasting it of course).
>
>cheers,
>prabhu
>_______________________________________________
>This is the private VTK discussion list.
>Please keep messages on-topic. Check the FAQ at: 
><http://public.kitware.com/cgi-bin/vtkfaq>
>Follow this link to subscribe/unsubscribe:
>http://public.kitware.com/mailman/listinfo/vtkusers




More information about the vtkusers mailing list