NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
niftkVTKIGIGeometry.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 niftkIGIGeometry_h
16 #define niftkIGIGeometry_h
17 
18 #include <vtkPolyData.h>
19 #include <vtkSmartPointer.h>
20 #include <vtkMatrix4x4.h>
21 
23 namespace niftk
24 {
25 
27 {
28 public:
29 
35  vtkSmartPointer<vtkPolyData> MakeLaparoscope(std::string rigidBodyFilename, std::string leftHandeyeFilename, std::string rightHandeyeFilename, std::string centreHandeyeFilename , bool AddCrossHairs = true, float trackerMarkerRadius = 3.0 , float LensAngle = 30.0, float BodyLength = 550 );
36 
42  vtkSmartPointer<vtkPolyData> MakePointer(std::string rigidBodyFilename, std::string handeyeFilename);
43 
49  vtkSmartPointer<vtkPolyData> MakeReference(std::string rigidBodyFilename, std::string handeyeFilename );
50 
56  vtkSmartPointer<vtkPolyData> MakeReferencePolaris(std::string rigidBodyFilename, std::string handeyeFilename );
57 
58 
65  vtkSmartPointer<vtkPolyData> MakeAWall( const int& whichwall, const float& size = 4000,
66  const float& xOffset = 0.0 , const float& yOffset = 0.0, const float& zOffset = -0.3,
67  const float& thickness = 10.0);
68 
74  vtkSmartPointer<vtkPolyData> MakeXAxes( const float& length = 4000,const bool& symmetric = false);
80  vtkSmartPointer<vtkPolyData> MakeYAxes( const float& length = 4000,const bool& symmetric = false);
86  vtkSmartPointer<vtkPolyData> MakeZAxes( const float& length = 4000,const bool& symmetric = true);
87 
91  vtkSmartPointer<vtkPolyData> MakeLapLensAxes();
92 
99  vtkSmartPointer<vtkPolyData> MakeOptotrak( const float & width = 500, bool Polaris = false);
100 
105  vtkSmartPointer<vtkPolyData> MakeTransrectalUSProbe(std::string handeyeFilename );
106 
111  vtkSmartPointer<vtkPolyData> MakeMonitor();
112 
113 private:
118  std::vector<std::vector <float> > ReadRigidBodyDefinitionFile(std::string rigidBodyFilename);
119 
123  vtkSmartPointer<vtkPolyData> MakeIREDs ( std::vector <std::vector <float> > IREDPositions,
124  float Radius = 3.0, int ThetaResolution = 8 , int PhiResolution = 8 );
125 
129  std::vector <float> Centroid(std::vector < std::vector <float> > );
130 
134  vtkSmartPointer<vtkPolyData> ConnectIREDs ( std::vector < std::vector <float> > IREDPositions , bool isPointer = false , float width = 0.0 );
135 
139  vtkSmartPointer<vtkPolyData> ConnectIREDsToCentroid ( std::vector < std::vector <float> > IREDPositions);
140 
141 };
142 } // end namespace
143 #endif
NIFTKIGIGUI_EXPORT std::vector< float[3]> ReadRigidBodyDefinitionFile(QString &rigidBodyFilename)
get the IRED positions from a rigid body definition file
Definition: niftkVTKIGIGeometry.h:26
mitk::Surface::Pointer MakeOptotrak(const float &width)
for visualisation purposes, make a representation of an Optotrak Certus camera unit ...
Definition: mitkMakeGeometry.cxx:134
mitk::Surface::Pointer MakeReferencePolaris(std::string rigidBodyFilename, std::string handeyeFilename)
For visualisation purposes, creates a representation of the reference.
Definition: mitkMakeGeometry.cxx:65
mitk::Surface::Pointer MakeAWall(const int &whichwall, const float &size, const float &xOffset, const float &yOffset, const float &zOffset, const float &thickness)
For visualisation purposes, make a wall of a cube.
Definition: mitkMakeGeometry.cxx:76
mitk::Surface::Pointer MakeXAxes(const float &length, const bool &symmetric)
For visualisation purposes, make a nice big axes.
Definition: mitkMakeGeometry.cxx:91
mitk::Surface::Pointer MakeZAxes(const float &length, const bool &symmetric)
For visualisation purposes, make a nice big axes.
Definition: mitkMakeGeometry.cxx:113
mitk::Surface::Pointer MakeLaparoscope(std::string RigidBodyFilename, std::string LeftHandeyeFilename, std::string RightHandeyeFilename, std::string CentreHandeyeFilename, bool AddCrossHairs, float TrackerMarkerRadius)
For visualisation purposes, creates a representation of the laparoscope.
Definition: mitkMakeGeometry.cxx:28
GLuint GLsizei GLsizei * length
Definition: glew.h:1809
mitk::Surface::Pointer MakePointer(std::string rigidBodyFilename, std::string handeyeFilename)
For visualisation purposes, creates a representation of the pointer.
Definition: mitkMakeGeometry.cxx:43
#define NIFTKVTK_WINEXPORT
Definition: niftkVTKWin32ExportHeader.h:28
mitk::Surface::Pointer MakeReference(std::string rigidBodyFilename, std::string handeyeFilename)
For visualisation purposes, creates a representation of the reference.
Definition: mitkMakeGeometry.cxx:54
mitk::Surface::Pointer MakeLapLensAxes()
a special type of axis useful for cameras
Definition: mitkMakeGeometry.cxx:124
mitk::Surface::Pointer MakeYAxes(const float &length, const bool &symmetric)
For visualisation purposes, make a nice big axes.
Definition: mitkMakeGeometry.cxx:102
mitk::Surface::Pointer MakeTransrectalUSProbe(std::string handeyeFilename)
For visualisation purposes, creates a representation of a transrectal ultrasound probe.
Definition: mitkMakeGeometry.cxx:154
mitk::Surface::Pointer MakeMonitor()
For visualisation purposes, creates a representation of a monitor.
Definition: mitkMakeGeometry.cxx:164
GLsizeiptr size
Definition: glew.h:1665
GLint GLint GLint GLint GLint GLint GLsizei width
Definition: glew.h:1236
Definition: niftkExceptionObject.h:21
GLsizei const GLcharARB ** string
Definition: glew.h:5194