Currently it is not possible to properly test the inetaction framework,
since it relies on user input. This bug is to fix this problem by providing the possibility to provide "user input" inside of a test, and by this to cover standardized user interaction within our test.
Currently it is not possible to properly test the inetaction framework,
|Duplicate||None||T16497 Data type for Segmentation|
|Wontfix||• schroedt||T16004 Implement a controller for Segmentation module.|
|Resolved||None||T16687 Tool tests using Interaction Testing Framework|
|Resolved||None||T16871 Interaction Testing Framework|
I've fixed several things in the plugin.
- The screen position is loaded during event creation.
- The Renderer is saved by its name in the interaction xml file for each event.
- When creating the event the name is used to look up for the renderer by calling mitk::BaseRenderer::GetByName. This should work as long the same RenderWindow is used for recording and playback. So in a test we might use StdMultiWidget as well.
Interaction is played back and also handled but somehow in reverse order for zooming, scrolling and moving. All inputs seem to point in the opposite direction. For instance if you record a zoom-in the playback will lead to a zoom-out. Haven't yet figure why. Press Release is in the right order. Because otherwise the interaction wouldn't work.
We found out that the inversion of the direction was due to an implicit conversion of the axis of displayPosition in the constructor of InteractionPositionEvent. Responsible for that was BaseRender::Map2DRendererPositionTo3DWorldPosition where GetDisplayGeometry()->ULDisplayToDisplay was used with the same variable for both parameters. This caused the y-axis to be flipped again when an event was created from the xml file.
Since the conversion/ axis flip of the display position from Qt events is necessary we moved the computation to QmitkRenderWindow. From there on we are now independent of the UI implementation and are only using VTK conform axis orientations.
We also moved the computation of the 3D world position to QmitkRenderWindow and provided an additional parameter in the constructor of InteractionPositionEvent. So we are able to set the world position when creating an event from the xml file.
The next step is to write a test helper class that builds all objects that are needed like a renderer, a data storage etc. And is able to playback interaction from a given xml file using the already available classes.
For Interactors that are using the display position (e.g. DisplayInteractor) it might be a bit tricky to write a proper test as the absolute positions of the input and the size of the render window must be the identical in test.
As long as the world position is used a test will be independent of the GUI.
Managed to playback scroll interaction the right way. There was a property missing in the xml file for ScrollDirection.
There are still some lines in BaseRenderer where ULDisplayToDisplay is used. Removing these leads to some weird crosshair interaction. Needs some more investigation. We should follow a concept where the y-axis flip is only done once an event is received by Qt.
Added an InteractionTestHelper class and an example for PointSetDataInteractor of how a test based on CPPUnit will look like.
Remove absolute path to files in test class. Add interaction xml file and reference data to MITK test data.
Did some additional stuff to get Tests working in all render windows of mitkWorkbench by providing three render windows with default view directions.
Also registered a DisplayInteractor to handle scroll, move and zoom events.
Added function to InteractionTestHelper to set timestep for 4D data support.
Unregister Renderer instances in destructor.
- Added config section to interaction file for renderer names and default view directions to dynamically create render-windows in helper class.
- Support for KeyPressEvent.
- Setter for timeStep of all render-windows.
User schroedt has pushed new remote branch:
[30c0e8]: Merge branch 'bug-16871-Interaction-Testing-Framework-integration'
2014-02-27 11:25:34 Tobias Schroeder [052e59]
Adapted to new API of InteractionPositionEvent.
2014-02-27 11:25:04 Tobias Schroeder [501b6f]
2014-02-27 11:24:13 Tobias Schroeder [d97bfc]
2014-02-27 11:23:21 Tobias Schroeder [873a5c]
Remove unused include.
2014-02-27 11:22:48 Tobias Schroeder 
Moved private static member functions to cpp file.
2014-02-27 11:21:56 Tobias Schroeder [9f4052]
Added test data to MITK-Data.
2014-02-27 08:38:19 Tobias Schroeder [f9dafe]
Merge branch 'bug-16871-InteractionRecorderWriter' into bug-16871-Interaction-Testing-Framework-integration
2014-02-24 11:54:24 Tobias Schroeder [84a39a]
Fix setting timesteps
2014-02-24 11:35:30 Tobias Schroeder [3dcd8f]
Added support for InteractionKeyEvent
2014-02-21 12:37:39 Tobias Schroeder [a0f79d]
helper class is no member
2014-02-21 12:36:00 Tobias Schroeder [0585e1]
Added access to renderWindows
2014-02-20 14:41:15 Tobias Schroeder [20ebce]
Added tooltips for buttons.
2014-02-20 14:40:50 Tobias Schroeder [e91902]
Undo smartpointer support.
2014-02-18 12:23:46 Tobias Schroeder [5ea649]
Renamed members of PointSetDataInteractorTest
2014-02-18 09:55:37 Tobias Schroeder [b1274f]
Use itk smartpointer for test helper class.
2014-02-18 09:39:26 Tobias Schroeder [7ec2d0]
Refactored test helper class to dynamically load RenderWindows from xml file.
2014-02-18 09:03:22 Tobias Schroeder [8c3f49]
2014-02-17 13:17:15 Tobias Schroeder [f77819]
Use xml header and write config for renderers.
2014-02-14 15:07:12 Tobias Schroeder [68eda6]
Changed test to take care of destruction.
2014-02-14 15:03:22 Tobias Schroeder [a6ee30]
Added renderwindows for the 3 default view directions.
Also added support for setting timesteps.
2014-02-07 10:59:44 Tobias Schroeder [7f577e]
2014-02-07 10:56:51 Tobias Schroeder 
Remove all unnecessary code
2014-02-07 09:41:54 Tobias Schroeder [5c5c0f]
Class documentation for InteractionTestHelper
2014-02-07 09:10:37 Tobias Schroeder 
Added a working test based on CPPUnit. TODO: remove absolute paths to files.
2014-02-07 09:09:07 Tobias Schroeder [a732c3]
Fix compile errors
2014-02-06 14:47:38 Tobias Schroeder [ba3f82]
Changed getter for renderer and render window
2014-02-06 14:20:29 Tobias Schroeder [8a4fd0]
Initially added helper class
2014-02-06 14:19:34 Tobias Schroeder [3ae5de]
Use first renderer if no one was found by name
2014-02-06 12:50:43 Tobias Schroeder [ab15a6]
Managed to playback scroll interaction the right way.
There are still some lines in BaseRenderer where ULDisplayToDisplay is used. Removing these lead to weird crosshair interacion. Needs some more investigation.
2014-02-06 12:49:59 Tobias Schroeder [b3ab38]
Removed axis-flip in VtkEventAdapter
2014-02-06 10:41:06 Tobias Schroeder [064a6a]
2014-02-06 10:40:13 Tobias Schroeder [92edd8]
Added new plugin icon.
2014-02-05 16:37:46 Christian Weber [5126c2]
Transform 2d to 3d point before creating Position events, to stay independent
of Display implementation.
Remove now unneccesary axis flips in vtkEventAdapter (since it used to be flipped
2014-02-05 15:16:07 Christian Weber [9aca78]
Fix event modification in BaseRenderer - Map2DRendererPositionTo3DWorldPosition
subsequently update the DisplayInteractor
2014-02-03 14:08:04 Tobias Schroeder [06b42c]
Save and Load funcionality for Renderer.
Interection is played back and handled but somehow in reverse order for zooming, scrolling and moving. All inputs seem to lead in the opposite direction. For instance if you record a zoom in the play back will lead to a zoom out.
2014-02-03 14:07:22 Tobias Schroeder [1fc936]
Icons for buttons
2014-02-03 09:59:24 Tobias Schroeder [84974b]
Parse screen position
2014-02-03 09:58:44 Tobias Schroeder [6e29ff]
Opening and closing tag in xml file
2014-02-03 09:57:16 Tobias Schroeder [1571ff]
Open file dialog for interaction file
2014-01-31 11:52:41 Tobias Schroeder [1ca7c2]
Fixed BAD_ACCESS during playback
2014-01-29 17:23:57 Christian Weber [c0b566]
Add XML Reader of Event Files.
2014-01-29 15:11:06 Christian Weber [6d4692]
move recorder initaialization into plugin
2014-01-29 15:10:48 Christian Weber [d96cfb]
fix in xml syntax
2014-01-29 14:31:14 Christian Weber [751be9]
+ WriteSupport for event recorder
+ Plugin Stub to use event recorder
2014-01-22 17:04:20 Christian Weber [0222c5]
- debug o
2014-01-22 16:58:24 Christian Weber [871c39]
mix up, position in world / screen
2014-01-22 16:51:59 Christian Weber [9f6217]
fix: ignored some parameters in mousewheel events.
2014-01-22 16:49:13 Christian Weber [5bdc9c]
Wrote EventObserver that transforms all events into XML,
attached ot to mousemode switcher (ONLY for testing!)
2014-01-22 16:48:33 Christian Weber [3a5bd6]
Extended EventConsts to describe events
2014-01-22 16:48:06 Christian Weber [10fab8]
Extended Event Factory to Map InteractionEvents to XML description
[accf5d]: Merge branch 'bug-16871-fix'
2014-02-27 12:49:16 Tobias Schroeder [b8f1a7]
COMP: fix windows compile errors.
: Merge branch 'bug-16871-fix'
2014-02-27 14:42:33 Tobias Schroeder [4656a5]
COMP: mitkFiberfoxAddArtifactsToDwiTest used wrong data because of MITK-Data update.
[5d6013]: Merge branch 'bug-16871-fix'
2014-02-27 15:51:31 Tobias Schroeder 
COMP: Use cmake variable MITK_ENABLE_RENDERING_TESTING to enable interaction test. Avoid crash on linux due to vtkRenderWindow creation.
Adapted classes according to code review.
Since mitkInteractionTestHelper is currently requiring an mitkRenderWindow to set up the test environment there is a need to turn off tests that use mitkInteractionTestHelper if the OS is Linux. Thus MITK_ENABLE_RENDERING_TESTING is checked in file.cmake.
Missing 3D render window support moved to T17375.
[5332ae]: Merge branch 'bug-16871-fix'
2014-03-05 13:52:06 Tobias Schroeder [d43595]
Module was renamed
2014-03-05 12:38:02 Tobias Schroeder [3141ca]
Fix cmake output