[vtkusers] Picking composite/hybrid actors such as vtkAxesActor

Renaud Lebrun renaud.lebrun at umontpellier.fr
Tue Jan 24 10:18:44 EST 2017


Hello,

I write you because I have troubles to manage to pick "composite/hybrid" 
actors comprising :
- 1 vtkActor
- 1 vtkCaption2D actor

I followed the same design as the "vtkAxesActor" class to create a class 
which contains 2 actors :
- vtkActor which represents a sphere constructed with a vtkSphereSource
- Alabel (a vtkCaptionActor2D actor).

=> I would like to be able to pick these composite/hybrid actors with an 
interactor style such as "vtkInteractorStyleRubberBandPick" in order to 
move their position, reoriente them interactively etc.

But unfortunately, the area picker never returns one of these 
composite/hybrid objects when calling areaPicker->GetProp3Ds();
(it finds well conventional vtkActors containing polydata only though)

One illustration is on the following image:
http://morphomuseum.com/img/picking.jpg
1) I manage to pick with no problem the "actor" containing the largest 
yellow structure (once picked I can change its orientation-position 
etc...).
2) I can't pick anly of the composite/hybrid actors (the red spheres 
associated with a number = 3D landmarks)

Would you have an advice to make it possible to pick composite 3D 
structures containing  polydata+ associated text ?
Many thanks in advance.
Best wishes,
Renaud.



More information about the vtkusers mailing list