Plugin for voxel-like representation

Hi all,

I am working on a plugin to load and visualize a voxel-like structure called Block, which uses on-the-fly decompression to reduce memory footprint (compared to vtkImageData). I already have a class called vtkBlockDataset that inherits from vtkImageData, a vtkBlockReader to load the structure from a file and a vtkBlockMapper to render it.
For the plugin I already managed to add the reader, but I am struggling with the representation. My goal is to have one more entry in the Display(UniformGridRepresentation) combobox called “Block view” that shows my vtkBlockDataset in the viewport, with no further settings. I already tried to write a vtkBlockRepresentation class that inherits from a Paraview representation (tried inheriting from vtkPVDataRepresentation, vtkGeometryRepresentationWithFaces, vtkSurfaceRepresentation) but to be frank it is mostly trial and error to see if something works, since the HowTo Plugin was not too helpful. I have also been looking at other representation plugins like NVidia index which is properly documented, but it is not clear to me how many methods I need to copy from it.

Which are the key methods/classes I need to implement to have the structure visible in Paraview? What is the flow Paraview follows to go from the reader’s output to an image in the viewport?
Any tips would be greatly welcomed :slight_smile: