Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consolidate InteractorStyle integration #123

Closed
jcfr opened this issue Aug 28, 2023 · 1 comment · Fixed by #131
Closed

Consolidate InteractorStyle integration #123

jcfr opened this issue Aug 28, 2023 · 1 comment · Fixed by #131

Comments

@jcfr
Copy link
Contributor

jcfr commented Aug 28, 2023

Currently vtkVirtualRealityViewInteractorStyle derives from vtkMRMLViewInteractorStyle so that the style can be associated with the displayable manager group1.

This is required to allow the Slicer VTK widgets to handle events.

This approach require to duplicate some of the code implemented in vtkVRInteractorStyle2

Questions

  • Should some of the logic in vtkVRInteractorStyle be moved to static function or helper class ?

Footnotes

  1. a displayable manager group is collection of displayable managers each adding support for capability like volume rendering, markups, transform, ... in a given view.

  2. https://github.com/Kitware/VTK/blob/master/Rendering/VR/vtkVRInteractorStyle.cxx

@jcfr jcfr changed the title Consolidate IntractorStyle integration Consolidate InteractorStyle integration Oct 6, 2023
@LucasGandel
Copy link
Contributor

Should some of the logic in vtkVRInteractorStyle be moved to static function or helper class ?

This sound difficult due to most of the logic being based on internal class variables. However can we consider it the other way round?
It should be possible to use vtkVRInteractorStyle directly and have a delegate class that observes the interactor style events. This delegate class should store the DisplayableManagers and be responsible for calling the dispatch event function. I am just not sure how easy the DisplayableManagers can be set on this delegate to replace how it is done currently for vtkMRMLViewInteractorStyle

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants