Switching between renderers in vtkRenderWindow

So I have an application where I have multiple vtkRenderers which I would like to quickly switch between in my vtkRenderWindow. The vtkRenderWindow appears to keep a collection of renderers, are all of these supposed to be displayed at once, is it possible to disable a single or many renderer(s)?

Yes all of the renderers are supposed to be displayed at once. This is commonly used for both side by side and overlay views. In the case of overlays, only the lowest layer clears the background before a render, with all higher layers clearing only the depth buffer so that they draw on top of the lower layer(s).

I have not seen this feature used for fast switching before. You could try doing it by managing the SetErase() and SetDraw() states yourself so that only the renderers you want to be active are allowed to do either thing.

1 Like