I’m migrating a project from vispy to VTK to visualize OCT volumes (mainly because VTK seems to have better memory management than vispy in our tests). However, I have issues optimizing the transfer function for our data. I read in other threads that a common approach is to experiment with transfer functions in Slicer, then implement the same transfer function in VTK. Unfortunately, I’m pretty confused by the results. I.e., the outputs from VTK and Slicer are very different, even though I’m using the same transfer function, as far as I understand. See the following screenshots:
Output from VTK:
Output from Slicer:
The transfer function I implemented in VTK is quite simple, a vtkPiecewiseFunction
for opacity with 3 points and a vtkColorTransferFunction
, also with 3 points. I entered the same values in Slicer, but there’s probably something else going on. What am I doing wrong?