Volume Masking

I have a volume and a labelmap and using paintfilter, I got this labelmap drawn on the volume with red, I want to use the labelmap as a binary mask for the volume.

image

I want to only show the cells of the volume at the labels indices without the need of changing the data (binary multiplication of volume with labelmap)

Hi, this could readily be a vtk.js filter. AFAIK we do not have such a filter, but we can add one. The usage would look something like volume -> thresholdFilter -> mapper/actor/renderer.

If you are interested, you can contribute such a filter. We may have time to create one, but it won’t be priority right now. You can learn how to develop vtk.js classes, and see an example of a similar filter in the ImageCropFilter.