diff --git a/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGTExampleIGT_QT_Tutorial_PluginView.png b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/IGTExampleIGT_QT_Tutorial_PluginView.png similarity index 100% rename from Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGTExampleIGT_QT_Tutorial_PluginView.png rename to Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/IGTExampleIGT_QT_Tutorial_PluginView.png diff --git a/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/IGT_TrackingLab_PluginView.png b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/IGT_TrackingLab_PluginView.png new file mode 100644 index 0000000000..bf0f649303 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/IGT_TrackingLab_PluginView.png differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTrackingLab.dox b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTrackingLab.dox index ea52e517f2..ac7a0c5bd9 100644 --- a/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTrackingLab.dox +++ b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTrackingLab.dox @@ -1,67 +1,69 @@ /** -\page org_igttrackinglab IGT Tutorial Step 4: The IGT-TrackingLab +\page org_igttrackinglab IGT Tutorial Step 5: The IGT-TrackingLab Available sections: - \ref QmitkIGTTrackingLabUsersManualOverview - \ref QmitkIGTTrackingLabUsersManualPrel - \ref QmitkIGTTrackingLabUsersManualConf - \ref QmitkIGTTrackingLabUsersManualIntialReg - \ref QmitkIGTTrackingLabUsersManualPermReg - \ref QmitkIGTTrackingLabUsersManualPtSetRec - \ref QmitkIGTTrackingLabUsersManualCamView + \section QmitkIGTTrackingLabUsersManualOverview Introduction -The IGT-TrackingLab is the last step of the IGT tutorial. It is a plugin which shows examples usage for many IGT classes and is also an example navigation implemented with IGT. In the following you can learn how to use the plugin by reading this manual together with the source code. Most important code passages are included in this manual. +The IGT-TrackingLab is the last step of the IGT tutorial. In the following you can learn how to use the plugin by reading this manual. IGT-TrackingLab shows example usage for many IGT classes and is also an example navigation implemented with IGT. The symbol of the Tracking Lab View is the following: -\imageMacro{../../resources/IgtTrackingLab.png,"",2} +\imageMacro{../../resources/icon_igt_tracking_lab.png,"",2} The view looks like this: \imageMacro{IGT_TrackingLab_PluginView.png,"",15.90} -TODO - explain here, what will happen... e.g. register a book, ... +With this tutorial you will register a book using a tracking device of your choice and the MITK's book surface file. The registration will enable you to move the book in the real world and observe its movement in the MITK display. It also allows you to record PointSets or use the CameraView which simulates a Camera at the tip of your pointer. \section QmitkIGTTrackingLabUsersManualPrel Preliminaries First connect your tracking device to your PC. Then start the MITK Workbench and configure your tracking device using the \ref org_mitk_views_igttrackingtoolbox "Tracking Toolbox View". TODO - here should be an option to use previously recorded data. \section QmitkIGTTrackingLabUsersManualConf Configuration Select the desired Navigation Data Source. Now it's time to define which tool shall be used as object marker and which tool shall be used as pointer. Next load the Book surface -provided with the example data (e.g. book.stl from the MITK-Data repository which comes with every superbuild or may also be checked out separately) into MITK. Fixate the object marker on a real book of your choice. Now we need to tell MITK that the object marker has been fixated on a physical object. To do this, select the Book as surface in the Object Selection submenu. +provided with the example data (e.g. book.stl from the MITK-Data repository which comes with every superbuild or may also be checked out separately) into MITK. Fixate the object marker on a real book of your choice. Now we need to tell MITK that the object marker has been fixated on a physical object. To do this, select the Book as surface in the Object Selection submenu as you can see in the screenshot above. \section QmitkIGTTrackingLabUsersManualIntialReg Initial Registration Now we need to register the object marker to the surface it's fixed upon, in our case the book. To do this, first press the initial registration button. For MITK to be able to do this registration, we need to 1. Select landmarks on the virtual object (e.g. the corners of the book) Press the plus button in the Image fiducials column. Shift + click on the corners on the book in the MITK Display. 2. Point to the corresponding landmarks in the real world using the pointer. Now press the plus button in the Real world fiducials column and point to the corners on the real book. Press Add current instrument position whenever you targeted a corner to tell MITK this is the desired landmark. Make sure you select the "real" edges in the same order as the edges in the image. +\imageMacro{IGT_TrackingLab_InitialRegistration.png,"Here the landmarks of the virtual object are already set",15.90} Press Register to finalize the initial registration. Now the object marker is registered onto the book. You can see this in the MITK image. If needed the FRE is shown in the widget. \section QmitkIGTTrackingLabUsersManualPermReg Permanent Registration Now everything is set up and registered. We can thus activate permanent registration to continuously track the object, the object marker and the pointer. For this, simply press the Permanent Registration button and select Activate permanent registration. You can now move the book in the real world and see the same movement in the MITK Display. A nice test to see if everything was correctly registered is to target the corners of the book with the pointer and check if the correct corners are pointed to in the MITK Display. \section QmitkIGTTrackingLabUsersManualPtSetRec PointSet Recording A user might now want to track a tool's trajectory. For this, the PointSet Recording was created. First click on PointSet Recording. Now select your tracking source and the tool whose trajectory shall be recorded. Activate the Point Set Recording checkbox. In the MITK Display little green points will now be drawn for every measured position. Deactivate the checkbox to stop recording. The trajectory is saved in the PointSet Recorded Points visible in the Data Manager. \section QmitkIGTTrackingLabUsersManualCamView Camera View Another possible tracking application is the Camera View. Here, a virtual camera is placed at the pointers tip and its images are shown in the MITK Display. Select Camera View and as usual the Tracking Source and the tool you want to place the virtual camera on. Activate the "Activate Needle View" checkbox and move the pointer around the book. You can now see the book from the pointers perspective. You may need to adjust the Needle View Direction and the View Up Vector. This is always relative to your tools coordinate center origin. An example of the NDI pointer tool coordinate system is shown below: \imageMacro{QmitkIGTExamples_Tool.png,"The coordinate system of the NDI pointing tool",16.00} In the above case, the camera should look in inverse z-direction, and the view up vector should probably be set to positive x. Note this is just an example and may be different depending on your pointer. \ref Return to the \ref IGTTutorialOverview "[IGT Tutorial Overview]" */ \ No newline at end of file diff --git a/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTutorial.dox b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTutorial.dox index 6c95608409..eba1dfcd3a 100644 --- a/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTutorial.dox +++ b/Plugins/org.mitk.gui.qt.igtexamples/documentation/UserManual/QmitkIGTTutorial.dox @@ -1,90 +1,94 @@ /** \page org_imageguidedtherapytutorial The MITK-IGT Tutorial View This view is not meant as an end-user module. It contains tutorial program code that explains how to use the MITK-IGT component. It contains only two buttons. The "Start image guided therapy" button will create a virtual tracking device and a virtual tool. It will move the tool around on random paths in a tracking volume of 200x200x200 mm. The tool is visualized with a cone. If you do not see a cone moving around, you will need to initialize the rendering views correctly. Use the DataManager view to perform a global reinit. The symbol of this view is the following: -\imageMacro{../../resources/IGTTutorial.png,"",2} +\imageMacro{../../resources/icon_igt_simple_example.png,"",2} + +and the whole view looks like this: + +\imageMacro{IGTExampleIGT_QT_Tutorial_PluginView.png,"",2} In this tutorial we connect to the NDI Polaris tracking system (or alternatively use a virtual tracking device) and we will show the movement of a tool as cone in the StdMultiWidget editor. First of all, you will have to add an IGT dependency to your cmake list. FOr this example, MitkIGTUI would be sufficient, but as the plugin contains several views, we have additional OpenIGTLink and US dependencies: \code{.cpp} project(org_mitk_gui_qt_igtexamples) mitk_create_plugin( EXPORT_DIRECTIVE IGTEXAMPLES_EXPORT EXPORTED_INCLUDE_SUFFIXES src MODULE_DEPENDS MitkQtWidgetsExt MitkIGT MitkIGTUI MitkOpenIGTLink MitkOpenIGTLinkUI MitkUS ) \endcode More information on how to create your own plugin can be found here: \ref NewPluginPage When clicking the start button, a cone should move in the 3D view and stop after clicking the stop button. The view has several fuctions. Most of them deal with the basic functionality with the plugin (e.g. CreateQTPartControl or CreateConnections). For a deeper understanding, you might have a look at the files QmitkIGTTutorialView.cpp and QmitkIGTTutorialView.h For our IGT functionality, the following functions are important: \li OnStartIGT: Starts the navigation pipeline \li OnStopIGT: Disconnect the pipeline \li OnTimer: Updates the view Let's now have a deeper look at these functions. \section OnStartIGT OnStartIGT \snippet ../../src/internal/QmitkIGTTutorialView.cpp OnStart 1 We first check in a try environment, if we should use an NDI tracking device or a virtual device. Let's start with NDI, we hardcode the parameters here and give out a warning. In your propper application, the parameters should be set via the gui aswell (see \ref org_mitk_views_igttrackingtoolbox ), but for simplicity, we just set hardcoded parameters here. If you want to try it with your own NDI device, you need to adapt these parameters here in the code: \snippet ../../src/internal/QmitkIGTTutorialView.cpp OnStart 2 The tracking device has to be set to a source. For more information on the tracking pipeline, please have a look at the \ref IGTTutorialStepFilterPipeline. \snippet QmitkIGTTutorialView.cpp OnStart 3 Alternatively, we can setup a virtual tracking device. We create this device, set the bounds, add a tool and connect it to the source: \snippet QmitkIGTTutorialView.cpp OnStart 4 Now we need to connect the tracking system \snippet QmitkIGTTutorialView.cpp OnStart 5 For the visualisation, we need an object. Here, we create a red cone \snippet QmitkIGTTutorialView.cpp OnStart 6 The visualization filter will actually render the cone \snippet QmitkIGTTutorialView.cpp OnStart 7 For a continuous display, we need to call update, here we decide to do it every 100 ms using a timer. \snippet QmitkIGTTutorialView.cpp OnStart 8 Disable the selection of tracking devices during tracking: \snippet QmitkIGTTutorialView.cpp OnStart 8a For propper coding, you should always catch the exceptions: \snippet QmitkIGTTutorialView.cpp OnStart 9 \section OnTimer OnTimer Each time, the timer is updated, the following code is executed: \snippet QmitkIGTTutorialView.cpp OnTimer \section OnStopIGT OnStopIGT This function will stop the pipeline and clean up everything: \snippet QmitkIGTTutorialView.cpp OnStop You now have a very simple plugin, which creates an own tracking device and starts or stops tracking. Of course, for your more advanced project, you could implement a new tracking device to be available in every plugin (see \ref IGTHowToImplementATrackingDevice) or use already implemented tracking devices via the tracking toolbox and/or microservices. This small example should just show you the most simple way to start tracking. \ref Return to the \ref IGTTutorialOverview "[IGT Tutorial Overview]" */ \ No newline at end of file diff --git a/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGT_TrackingLab_InitialRegistration.PNG b/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGT_TrackingLab_InitialRegistration.PNG new file mode 100644 index 0000000000..907507d353 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGT_TrackingLab_InitialRegistration.PNG differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGT_TrackingLab_PluginView.png b/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGT_TrackingLab_PluginView.png deleted file mode 100644 index 42e03a1b76..0000000000 Binary files a/Plugins/org.mitk.gui.qt.igtexamples/documentation/doxygen/IGT_TrackingLab_PluginView.png and /dev/null differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/files.cmake b/Plugins/org.mitk.gui.qt.igtexamples/files.cmake index 085e0de10c..2e72b5f794 100644 --- a/Plugins/org.mitk.gui.qt.igtexamples/files.cmake +++ b/Plugins/org.mitk.gui.qt.igtexamples/files.cmake @@ -1,62 +1,52 @@ set(SRC_CPP_FILES ) set(INTERNAL_CPP_FILES QmitkIGTTrackingLabView.cpp QmitkIGTTutorialView.cpp OpenIGTLinkExample.cpp OpenIGTLinkProviderExample.cpp OpenIGTLinkPlugin.cpp mitkPluginActivator.cpp ) set(UI_FILES src/internal/QmitkIGTTrackingLabViewControls.ui src/internal/QmitkIGTTutorialViewControls.ui src/internal/OpenIGTLinkProviderExampleControls.ui src/internal/OpenIGTLinkExampleControls.ui src/internal/OpenIGTLinkPluginControls.ui ) set(MOC_H_FILES src/internal/QmitkIGTTrackingLabView.h src/internal/QmitkIGTTutorialView.h src/internal/OpenIGTLinkProviderExample.h src/internal/OpenIGTLinkExample.h src/internal/mitkPluginActivator.h src/internal/OpenIGTLinkPlugin.h ) -set(QRC_FILES - #resources/QmitkIGTTrackingLabView.qrc - #resources/QmitkIGTTutorialView.qrc -) - set(CACHED_RESOURCE_FILES - #resources/IgtTrackingLab.png resources/start_rec.png resources/stop_rec.png - #resources/IGTTutorial.png - #resources/icon.xpm - #resources/example.png - #resources/provider.png resources/icon_igt_simple_example.svg resources/icon_igt_tracking_lab.svg resources/icon_openigtlink_client_example.svg resources/icon_openigtlink_extended_example.svg resources/icon_openigtlink_provider_example.svg plugin.xml ) set(CPP_FILES ) foreach(file ${SRC_CPP_FILES}) set(CPP_FILES ${CPP_FILES} src/${file}) endforeach(file ${SRC_CPP_FILES}) foreach(file ${INTERNAL_CPP_FILES}) set(CPP_FILES ${CPP_FILES} src/internal/${file}) endforeach(file ${INTERNAL_CPP_FILES}) diff --git a/Plugins/org.mitk.gui.qt.igtexamples/resources/ReadMe_ChangeIcons.txt b/Plugins/org.mitk.gui.qt.igtexamples/resources/ReadMe_ChangeIcons.txt new file mode 100644 index 0000000000..bd75a511b3 --- /dev/null +++ b/Plugins/org.mitk.gui.qt.igtexamples/resources/ReadMe_ChangeIcons.txt @@ -0,0 +1 @@ +If you change icons, please change both - svg and png - as one is needed for the documentation and the other as plugin icon. \ No newline at end of file diff --git a/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_igt_simple_example.png b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_igt_simple_example.png new file mode 100644 index 0000000000..6d08792e7b Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_igt_simple_example.png differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_igt_tracking_lab.png b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_igt_tracking_lab.png new file mode 100644 index 0000000000..cdd3e37d36 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_igt_tracking_lab.png differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_client_example.png b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_client_example.png new file mode 100644 index 0000000000..982c00e0d3 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_client_example.png differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_extended_example.png b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_extended_example.png new file mode 100644 index 0000000000..b765309de4 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_extended_example.png differ diff --git a/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_provider_example.png b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_provider_example.png new file mode 100644 index 0000000000..7fab1feda6 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igtexamples/resources/icon_openigtlink_provider_example.png differ diff --git a/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkIGTRegistration.dox b/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkIGTRegistration.dox new file mode 100644 index 0000000000..13a3509625 --- /dev/null +++ b/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkIGTRegistration.dox @@ -0,0 +1,6 @@ +/** + +\page org_mitk_views_igtregistrationview The IGT Registration view + + +\imageMacro{QmitkIGTTracking_RegistrationView.png,"Icon of the MITK-IGT Tracking Toolbox",2.00} \ No newline at end of file diff --git a/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkIGTTracking_RegistrationView.png b/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkIGTTracking_RegistrationView.png new file mode 100644 index 0000000000..891a9f4d00 Binary files /dev/null and b/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkIGTTracking_RegistrationView.png differ diff --git a/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkMITKIGTNavigationToolManager.dox b/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkMITKIGTNavigationToolManager.dox index 57249fb3c1..5c84813a8f 100644 --- a/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkMITKIGTNavigationToolManager.dox +++ b/Plugins/org.mitk.gui.qt.igttracking/documentation/UserManual/QmitkMITKIGTNavigationToolManager.dox @@ -1,53 +1,53 @@ /** \page org_mitk_views_igtnavigationtoolmanager The MITK-IGT Navigation Tool Manager -\imageMacro{../resources/iconTrackingToolManager.svg,"Icon of the Navigation Tool Manager",2.00} +\imageMacro{../resources/iconTrackingToolManager.png,"Icon of the Navigation Tool Manager",2.00} \section QmitkMITKIGTNavigationToolManager Introduction This view allows for creating and editing NavigationToolStorages. These storages contains naviagtion tools of a tracking device, can be saved permanently and used later for any other IGT application. \tableofcontents \section QmitkMITKIGTNavigationToolManagerToolOverview Navigation Tools Overview A navigation tool of MITK-IGT represents a tracking tool (e.g. an emt sensor or an optically tracked tool) and it's corresponding data, like it's name and it's surface. A navigation tool is a generalized container for any trackable object in combination with it's additional information. Every navigation tool has different properties which are: