if Foreground renderers are added to the VtkLayerController, picking is not possible because those renderers clear the z-buffer.
PreserveDepthBuffer has to be set true for all renderers above the actual scene layer.
Description
Related Objects
- Mentioned Here
- T18735: Meta analysis of Interaction/Rendering/geometries
Event Timeline
User kolbch has pushed new remote branch:
bug-18752-PreserveDepthBufferInForegroundRenderers
in mitk::VtkLayerController::InsertForegroundRenderer:
+ renderer->PreserveDepthBufferOn();
This prevents the foreground renderers from clearing the z-buffer, as they are rendered last, but usually don't contain any items that the user wants to pick.
The bug was never noticed because it is only an issue if there are more than one layers in the VtkLayerController.
It would be best to reduce the usage of layered renderers, as they currently only contain 2D actors which are rendered last anyway, but the z-buffer issue should still be fixed.
The 3D worldpoint picking will be tested with interaction tests, which are developed in the context of T18735
[4f04fb]: Merge branch 'bug-18752-PreserveDepthBufferInForegroundRenderers'
Merged commits:
2015-02-18 22:25:18 Christoph Kolb [e68785]
PreserveDepthBufferOn to all foreground renderers