NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
QmitkIGIUtils.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef QmitkIGIUtils_h
16 #define QmitkIGIUtils_h
17 
18 #include "niftkIGIGuiExports.h"
19 #include <mitkSurface.h>
20 #include <QString>
21 #include <vtkMatrix4x4.h>
23 #include "igtlTypes.h"
24 
29 NIFTKIGIGUI_EXPORT mitk::Surface::Pointer LoadSurfaceFromSTLFile(QString& surfaceFilename);
30 
34 NIFTKIGIGUI_EXPORT QString CreateTestDeviceDescriptor();
35 
40 NIFTKIGIGUI_EXPORT bool SaveMatrixToFile(const vtkMatrix4x4& matrix, const QString& fileName);
41 
45 NIFTKIGIGUI_EXPORT void ApplyTransformToSelectedNodes(const vtkMatrix4x4& transform, const niftk::DataStorageCheckableComboBox& comboBox);
46 
50 NIFTKIGIGUI_EXPORT void ComposeTransformWithSelectedNodes(const vtkMatrix4x4& transform, const niftk::DataStorageCheckableComboBox& comboBox);
51 
57 NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakeLaparoscope(QString& rigidBodyFilename, const vtkMatrix4x4& handeye );
58 
64 NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakePointer(QString& rigidBodyFilename, const vtkMatrix4x4& handeye );
65 
71 NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakeReference(QString& rigidBodyFilename, const vtkMatrix4x4& handeye );
72 
79 NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakeAWall( const int& whichwall, const float& size = 3000,
80  const float& xOffset = 0.0 , const float& yOffset = 0.0, const float& zOffset = -0.3,
81  const float& thickness = 10.0);
82 
87 NIFTKIGIGUI_EXPORT std::vector<float [3]> ReadRigidBodyDefinitionFile(QString& rigidBodyFilename);
88 
92 NIFTKIGIGUI_EXPORT QString ConvertNanoSecondsToString(const igtlUint32& nanosec);
93 
94 #endif
NIFTKIGIGUI_EXPORT std::vector< float[3]> ReadRigidBodyDefinitionFile(QString &rigidBodyFilename)
get the IRED positions from a rigid body definition file
NIFTKIGIGUI_EXPORT void ApplyTransformToSelectedNodes(const vtkMatrix4x4 &transform, const niftk::DataStorageCheckableComboBox &comboBox)
Applies (sets, i.e. copies) the given transform to all checked nodes in the comboBox.
Definition: QmitkIGIUtils.cxx:177
NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakeLaparoscope(QString &rigidBodyFilename, const vtkMatrix4x4 &handeye)
For visualisation purposes, creates a representation of the laparoscope.
Definition: niftkDataStorageCheckableComboBox.h:51
NIFTKIGIGUI_EXPORT void ComposeTransformWithSelectedNodes(const vtkMatrix4x4 &transform, const niftk::DataStorageCheckableComboBox &comboBox)
Composes the given transform with all checked nodes in the comboBox.
Definition: QmitkIGIUtils.cxx:184
NIFTKIGIGUI_EXPORT mitk::Surface::Pointer LoadSurfaceFromSTLFile(QString &surfaceFilename)
For testing purposes, loads an STL file.
GLuint GLenum GLenum transform
Definition: glew.h:12775
NIFTKIGIGUI_EXPORT QString CreateTestDeviceDescriptor()
Creates a test NDI Polaris Vicra message, used for initial testing.
Definition: QmitkIGIUtils.cxx:64
NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakeAWall(const int &whichwall, const float &size=3000, const float &xOffset=0.0, const float &yOffset=0.0, const float &zOffset=-0.3, const float &thickness=10.0)
For visualisation purposes, make a wall of a cube.
Definition: mitkMakeGeometry.cxx:76
NIFTKIGIGUI_EXPORT QString ConvertNanoSecondsToString(const igtlUint32 &nanosec)
Converts an integer number of nanoseconds to a 9 digit string, prefixed with zeros.
Definition: QmitkIGIUtils.cxx:83
NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakePointer(QString &rigidBodyFilename, const vtkMatrix4x4 &handeye)
For visualisation purposes, creates a representation of the pointer.
GLuint GLenum matrix
Definition: glew.h:12775
GLsizeiptr size
Definition: glew.h:1665
NIFTKIGIGUI_EXPORT bool SaveMatrixToFile(const vtkMatrix4x4 &matrix, const QString &fileName)
Saves the matrix to file, returning true if successful and false otherwise. This function also raises...
Definition: QmitkIGIUtils.cxx:91
NIFTKIGIGUI_EXPORT mitk::Surface::Pointer MakeReference(QString &rigidBodyFilename, const vtkMatrix4x4 &handeye)
For visualisation purposes, creates a representation of the reference.