[vtkusers] Disabling interaction of a renderer
Slaughter, Andrew E
andrew.slaughter at inl.gov
Thu Jun 21 16:12:06 EDT 2018
After digging around a bit I figured out how to solve the problem, the
complete script with a working version is attached. In short the
vtkRenderWindowInteractor::FindPokedRenderer always returns a renderer
regardless of the Set/GetInteractive state. Therefore, I created a
"background" renderer with layer 0 with the others on layer 1. Using
SetInteractive(False) on the two layer 1 renders that causes the background
to be the fallback renderer for the interactor, which produces the desired
behavior.
Thanks to anyone who might of took time to look at my problem.
On Wed, Jun 20, 2018 at 9:13 AM, Slaughter, Andrew E <
andrew.slaughter at inl.gov> wrote:
> I am creating an application that will require the user to "activate" an
> object prior to being able to manipulate it via mouse movements. The
> attached script is simple (python2.7;vtk7.1;MacOS10.13.4) demonstration
> with two renderers (left and right). Pressing "t" toggles/highlights the
> contents.
>
> However, when the left side is highlighted I can still interact with the
> right side. How can I disable the interaction for a particular renderer?
>
> Thanks for the help,
>
> Andrew
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180621/d04ca840/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dual_toggle.py
Type: text/x-python-script
Size: 2459 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180621/d04ca840/attachment.bin>
More information about the vtkusers
mailing list