I have a large C++ application which uses VTK as a visualisation system. I plan to have some minimal binding of my C++ application in Python (using pybind11) allowing users to drive the application from Jupyter. Now it would be excellent to use the existing capabilities of trame.vtk to provide an interactive widget instead of my C++ vtkRenderWindow.
My question is then how is this most easily done? Is there any sensible way to get a python vtkRenderWindow object from a C++ object? Questions
- Is there any way of setting the internal python wrapped C++ pointer to something provided externally
- A custom class could be wrapped with the VTK python binding system, so that a C++ class could provide a wrapped python object (i.e vtkRenderWindow)
- Alternative mechanism for C++/python interoperation. e.g. some combination of RPC and offscreen rendering etc
Suggestions most welcome.