My ultimate goal is to develop a Clip filter wherein the user can specify three node IDs, and a Clip will be generated from the plane defined by the coordinate locations of those three nodes.
So far I have succeeded in the “lookup” portion of the plugin (EDIT: maybe not actually, this is another topic to be filed), and I can input three node IDs and return the coordinates of those nodes. However, now I face the task of how to actually process the Clip.
For the generation of a Clip for a single UnstructuredGrid dataset, I believe the example here: https://kitware.github.io/vtk-examples/site/Python/UnstructuredGrid/ClipUnstructuredGridWithPlane2/
will give me what I need (although I am not sure of that yet, either).
But my data is a MultiBlockDataSet comprised of many UnstructuredGrid blocks. So what is the best way to handle this? Do I iterate through the UnstructuredGrid blocks, applying the clip to each? And would I then have to reassemble these clipped blocks into a MultiBlockDataSet to get my output object?
I think there is an answer somewhere in this: https://github.com/Kitware/ParaView/blob/master/VTKExtensions/FiltersGeneral/vtkPVClipDataSet.cxx
but I am not C++ fluent and I’m having a hard time figuring out how this would map back to a Python VTK application.
Any help would be appreciated! I think my biggest roadblock right now is how to handle the multi-block structure, but there may be other things I am doing wrongly as well.