Rendering Multiple Volumes

Hi, I have a question. So here I am rendering 3 volumes together (different volume objects and mapper, but same renderer/renderwindow). I notice that at one angle, the volumes are not sorted properly.

For this image for example, the orange should appear behind the gray but yet…

As you can see here, the orange is rendering in front of the gray which should not be happening. Anyone knows why this is happening?

Is your vtk.js version at least 23.2.0 ?
This version introduced order-independent transparency, which solved some kind of rendering order bug for me. But I don’t remember if it was the same issue with volumes that you’re having.

@Ebrahim_Ebrahim “order-independent transparency” is only for meshes, not volumes.

ah, nevermind then

Multi-volume rendering in vtk.js is not well-supported for all cases yet. Last time I checked, volumes that do not occupy the same physical space (as is the case for your example) will have an ordering that is equivalent to the addVolume() order.

1 Like