I’m trying to create slices of an STL bone model and obtaining binary masks of each slice to be exported into numpy for further processing. I’m quite new in VTK and I’m a bit lost. My STL model to be sliced looks like this:
And I’m trying to create binary masks for those slices similar to this:
I’ve found examples for slicing Images but not PolyData. I need this to be done programatically without any external application. Could you give me any clue? It’s been a while that I’m stuck.
Thanks a lot!!