Can't enter selection mode in a rendered window

Hi everyone!

I’m having trouble entering the selection mode in a render window. Do I just click on ‘r’ on my keyboard? I’ve tried that but it doesn’t work. I’m not sure why that is…

Hello, friend!

Key ‘p’ works for me. A bounding box appears around the actor under the mouse pointer. Is it that you want?

regards,

Paulo

Thanks. I’m trying to enable the selection mode to select points points I’ve added to a polyData. Sometimes it enters the selection mode just fine by clicking ‘r’ but it’s not consistent.

Can you elaborate more? I mean: what is the expected behavior? What are you getting?

When I press r, it doesn’t allow me to enter selection mode and only does so sporadically. I’m not sure if the mode I’ve started with is incorrect or what might of caused it.

Hi, friend,

If I’m not mistaken, here are the default key bindings:

  • Keypress 3: toggle the render window into and out of stereo mode (requires red/blue or polarized glasses, depending on your device).
  • Keypress e: exit the application.
  • Keypress f: fly to the picked point
  • Keypress p: perform a pick operation.
  • Keypress r: reset the camera view along the current view direction. Centers the actors and moves the camera so that all actors are visible.
  • Keypress s: modify the representation of all actors so that they are surfaces.
  • Keypress u: invoke the user-defined function. Typically, this keypress will bring up an interactor that you can type commands in.
  • Keypress w: modify the representation of all actors so that they are wireframes.

To select actors, you need to implement a picking callback.

regards,

Paulo

I’m using vtkPolygonalSurfacePointPlacer and I’d like to select the points “picked.” Do I still need to implement a picking callback?

From the docs VTK: vtkPolygonalSurfacePointPlacer Class Reference :

Place points on the surface of polygonal data.

vtkPolygonalSurfacePointPlacer places points on polygonal data and is meant to be used in conjunction with vtkPolygonalSurfaceContourLineInterpolator.

To me it doesn’t seem to select actors…

I see. I’m trying to drag the points placed such that it would generate new lines(I’m using vtkPolygonalSurfaceContourLineInterpolator) connecting the points.

If you want to drag actors with the mouse you can try this: https://vtk.org/Wiki/VTK/Examples/Cxx/Visualization/MoveActor .