[vtkusers] Question about relationship between interactor/render window and QVTKRenderWindowInteractor

Elvis Stansvik elvis.stansvik at orexplore.com
Thu Jun 16 03:27:20 EDT 2016


2016-06-16 9:12 GMT+02:00 Elvis Stansvik <elvis.stansvik at orexplore.com>:

> Hi,
>
> QVTKRenderWindowInteractor.__init__ has the following snippet:
>
>         try:
>             self._Iren = kw['iren']
>         except KeyError:
>             self._Iren = vtk.vtkGenericRenderWindowInteractor()
>             self._Iren.SetRenderWindow(self._RenderWindow)
>

I see now that this snippet was added by Berk back in 2010:


https://gitlab.kitware.com/vtk/vtk/commit/2fc9c979ce248e491cff3486edaa729653f81a81

Berk, do you remember the reason for not setting the render window on the
interactor when it is user-supplied?

Elvis


>
> That is, the render window is only set on the interactor (with
> SetRenderWindow) if the interactor is the automatically created one, not if
> it is supplied by the user of the class (through the iren keyword argument).
>
> My question is what the reason for this is? Is it because:
>
>  1. It is assumed that the user will do this him/herself, or
>  2. there are use cases where the user might want to use an interactor
> that has another render window set (not the one used by the widget), or
>  3. something else?
>
> Thanks in advance,
> Elvis
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160616/675c3ce2/attachment.html>


More information about the vtkusers mailing list