NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
QmitkUltrasoundPinCalibrationWidget.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 QmitkUltrasoundPinCalibrationWidget_h
16 #define QmitkUltrasoundPinCalibrationWidget_h
17 
18 #include "niftkIGIGuiExports.h"
19 #include <QVTKWidget.h>
20 #include <QMouseEvent>
21 #include <QKeyEvent>
22 #include <QEvent>
23 #include <QString>
24 #include <vtkImageViewer.h>
25 #include <vtkSmartPointer.h>
26 #include <vtkImageReader2.h>
27 
32 class NIFTKIGIGUI_EXPORT QmitkUltrasoundPinCalibrationWidget : public QVTKWidget
33 {
34  Q_OBJECT
35 
36 public:
37 
39  const QString& inputImageDirectory,
40  const QString& outputPointDirectory,
41  QWidget *parent = 0
42  );
44 
48  virtual void mousePressEvent(QMouseEvent* event) override;
49 
60  virtual void keyPressEvent(QKeyEvent* event) override;
61 
65  virtual void enterEvent(QEvent* event) override;
66 
67  void SetPNG ( bool );
68 
69 private slots:
70 
71 private:
72 
73  const QString m_InputImageDirectory;
74  const QString m_OutputPointDirectory;
75 
76  vtkSmartPointer<vtkImageViewer> m_ImageViewer;
77  vtkSmartPointer<vtkImageReader2> m_ImageReader;
78  std::vector<std::string> m_ImageFiles;
79  int m_ImageWidth;
80  int m_ImageHeight;
81  unsigned long int m_ImageFileCounter;
82  unsigned long int m_PointsOutputCounter;
83  bool m_PNG; //by default we look for nii, but we can read png
84 
85  void NextImage();
86  void PreviousImage();
87  void QuitApplication();
88  void StorePoint(QMouseEvent* event);
89  void ShowImage(const unsigned long int& imageNumber);
90  void CreateDir(const std::string& dir);
91 };
92 
93 #endif // QmitkUltrasoundPinCalibrationWidget_h
Very prototypyish.. don't copy this one.
Definition: QmitkUltrasoundPinCalibrationWidget.h:32
cl_event event
Definition: glew.h:3231
GLsizei const GLcharARB ** string
Definition: glew.h:5194