PropPicker does not work for ViewProps anymore


In VTK 8.2, the PropPicker, which uses the renderers pick method, changed to use the hardware selector. It seems this selector does not work for general Props like an ImageActor. This means that the general PropPicker can’t be used to pick this kind of props.

The issue becomes apparent in the PickPixel2 example ([]), which keeps saying the mouse is ‘off image’. This example works fine for VTK 8.1.

If this change of behaviour was intentional, I can find a workaround using other pickers. However, this change was not very clear from the changelog (or I missed it) and required some digging to find out.

Kind regards,

As far as I know, hardware picker does not work for semi-transparent objects. If your image contains semi-transparent voxels (or just an alpha channel) then it may be rendered as translucent geometry and so not considered for picking. See some more information in this old discussion thread.

Setting ForceOpaqueOn or displaying an image without alpha channel might fix the picking issue.

Hi Andras,

This fix indeed solves the issue. I created a pull request to fix the example.


1 Like