Hi guys, I'm implementing the interactor to select some specific sub-objects but I have a problem making it work with the display interactor.
Basically, I want the following quite natural behavior in 3D window: - if a user clicks on the object of interest - it should be selected - if a user clicks and drags - the view should rotate without triggering the selection Basically, I have a DataInteractor that processes mouse release events in the state machine. What I do within it is the following: Within FilterEvents method: - On mouse press event, I record that dragging might have started and return mitk::DataInteractor::FilterEvents, which as far as I understand leads to returning true if there are any transitions for this event . In this case, I have no transitions for that event, so it is being passed to the vtk interactor style, which starts rotation. - On mouse move event, I record that dragging actually started, with the same return value as above. - On mouse release event, I check if there was any actual dragging. And if yes, I ignore the event by returning false so it would be passed to the vtk interactor style to stop the rotation. But if not - there is a transition and the event is accepted. The problem is that the vtk interactor style does not get the mouse release event in case a simple click was performed. Therefore it continues rotating even though no actual dragging is performed. What are your thoughts on how this can be fixed? What I see is that the action's return value is not used at all (see mitk::EventStateMachine::HandleEvent). Perhaps it could mean if the event should be passed through, similar to FilterEvents? Rostislav. ------------------------------------------------------------------------------ Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ _______________________________________________ mitk-users mailing list mitk-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mitk-users