vtkBillboardTextActor3D text always renders behind raycast volume

Displaying labels correctly is extremely difficult. I’ve spent a lot of time experimenting with different options for markup display in 3D Slicer, but each option has different limitations.

To tackle occlusion: To make sure the labels are not occluded, you can display 3D label actors on a separate layer or use 2D actors. However, then you need to manually hide the actors when the corresponding point of interest is occluded. In general, determining if a certain point is occluded is a very costly operation, so you either have to be smart when you do it (e.g., only when camera interaction is finished) or how you do it (e.g., using hardware acceleration). Label placement mapper can do some Z-buffer based visibility checks, but I could not make it work very accurately (label for occluded points are often still visible).

Overall, for me it seems that the label placement mapper is the closest to an acceptable solution, but some more fixes and improvements would be needed (make hiding label occlusion computation more robust, implement concident label repositioning, etc.).

It would be great to hear experience from others, too.

1 Like