New flag vtkRenderWindowInteractor::InteractorManagesTheEventLoop for event loop#
This flag is useful when you are integrating VTK in a larger system.
In such cases, an application can lock up if the Start() method
in vtkRenderWindowInteractor processes events indefinitely without
giving the system a chance to execute anything.
The default value for this flag is true. It currently only affects
VTK webassembly applications.
As an example with webassembly in the browser through emscripten SDK:
If your app has an
int mainentry point, leave this value enabled. Emscripten will simulate an infinite event loop and avoid running code afterinteractor->Start()which is usually the end ofmain. Otherwise, all VTK objects will go out of scope immediately without giving a chance for user interaction with the render window.If your app does not have an
int mainentry point, disable this behavior. Otherwise, the webassembly application will not start up successfully.