[Paraview] Python and ParaView: customizing mouse actions

Francesco Poli invernomuto at paranoici.org
Mon Apr 2 05:19:23 EDT 2018


Hello!

I am trying to visualize data with ParaView from a Python script.
After creating a render view with paraview.simple.CreateRenderView(),
I set its InteractionMode to '2D', since the data are two-dimensional
and I am not interesting in rotating them.

After loading the data and setting some options, the scripts runs:

    paraview.simple.Render()
    paraview.simple.Interact()

Everything seems to work, but I would like to customize the camera
movements associated with mouse events.
By default, with 2D InteractionMode, I get:

 • left mouse button → Pan
 • middle mouse button → Roll
 • right mouse button → Zoom
 • mouse wheel → Zoom

I would like to change the camera movements associated with these mouse
events.
I searched the documentation about ParaView Python scripting, including
the paraview.simple
[module documentation](https://www.paraview.org/ParaView/Doc/Nightly/www/py-doc/paraview.simple.html),
but failed to find any useful hint.

Could someone please tell me where I can find documentation about this
topic?

Thanks for your time!
Bye.


-- 
 http://www.inventati.org/frx/
 There's not a second to spare! To the laboratory!
..................................................... Francesco Poli .
 GnuPG key fpr == CA01 1147 9CD2 EFDF FB82  3925 3E1C 27E1 1F69 BFFE
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/paraview/attachments/20180402/906787a9/attachment.sig>


More information about the ParaView mailing list