Hey all,
I’m looking to use a timer event to run a function and I’m looking for an example. I’m on python 3.10.11 and vtk 9.3.0. Any snippets or examples would be greatly appreciated.
Thanks in advance!
Hey all,
I’m looking to use a timer event to run a function and I’m looking for an example. I’m on python 3.10.11 and vtk 9.3.0. Any snippets or examples would be greatly appreciated.
Thanks in advance!
Hello @cam
Yes, you can do this in python using VTK interactors. I understand you want a Python example, but this should help you. Here is a C++ example - https://examples.vtk.org/site/Cxx/Utilities/Timer/ that shows how to create a timer callback function that observes timer events. You can easily convert that observer portion from C++ to python by following this guide - https://examples.vtk.org/site/Python/Interaction/CallBack/#python