MITK-IGT
IGT Extension of MITK
Loading...
Searching...
No Matches
QmitkUltrasoundSupport.h
Go to the documentation of this file.
1/*============================================================================
2
3The Medical Imaging Interaction Toolkit (MITK)
4
5Copyright (c) German Cancer Research Center (DKFZ)
6All rights reserved.
7
8Use of this source code is governed by a 3-clause BSD license that can be
9found in the LICENSE file.
10
11============================================================================*/
12
13#ifndef QmitkUltrasoundSupport_h
14#define QmitkUltrasoundSupport_h
15
16#include <mitkLookupTable.h>
17#include <mitkLookupTableProperty.h>
18
19#include <berryISelectionListener.h>
20
21#include <QmitkAbstractView.h>
22
27#include <mitkBaseRenderer.h>
28#include "QmitkRenderWindow.h"
29#include <mitkStandaloneDataStorage.h>
30#include <QmitkLevelWindowWidget.h>
31#include <QmitkSliceWidget.h>
32
33#include <QElapsedTimer>
34
35#include <ctkServiceEvent.h>
36
37namespace Ui
38{
39 class UltrasoundSupportControls;
40}
41
48class QmitkUltrasoundSupport : public QmitkAbstractView
49{
50 // this is needed for all Qt objects that should have a Qt meta-object
51 // (everything that derives from QObject and wants to have signal/slots)
52 Q_OBJECT
53
54public:
55
56 void SetFocus() override;
57
58 static const std::string VIEW_ID;
59
60 void CreateQtPartControl(QWidget *parent) override;
61
63 ~QmitkUltrasoundSupport() override;
64
65 public slots:
66 /*
67 * \brief This is called when the newDeviceWidget is closed
68 */
70
71 protected slots:
72
74
76
78
79 /*
80 *\brief Called, when the selection in the list of the active devices changes.
81 */
83
85
86 void OnDeviceServiceEvent(const ctkServiceEvent event);
87
88 /*
89 * \brief This is the main imaging loop that updates the image and is called regularly during the imaging process
90 */
91 void UpdateImage();
92
93 void RenderImage2d();
94
95 void RenderImage3d();
96
97 void StartTimers();
98
99 void StopTimers();
100
101protected:
102
105
106 Ui::UltrasoundSupportControls* m_Controls;
107
112
114
117
119 unsigned int m_AmountOfOutputs;
120
122 mitk::USDevice::Pointer m_Device;
123
124 void SetTimerIntervals(int intervalPipeline, int interval2D, int interval3D);
129
131 QElapsedTimer m_Clock;
132 QElapsedTimer m_Clock2d;
133 QElapsedTimer m_Clock3d;
134
140
142 void StoreUISettings();
143
145 void LoadUISettings();
146
148 std::vector<mitk::DataNode::Pointer> m_Node;
155
159
160 void SetColormap(mitk::DataNode::Pointer node, mitk::LookupTable::LookupTableType type);
161
163 std::vector<mitk::Image::Pointer> m_curOutput;
164
167 mitk::SlicedGeometry3D::Pointer m_OldGeometry;
168
169 QList<ctkServiceReference> m_CustomWidgetServiceReference;
170
172
173 /* Spacing calibration variables and methods */
176 double ComputeSpacing(mitk::Point3D p1, mitk::Point3D p2, double distance);
177 protected slots:
178 void SetXPoint1();
179 void SetXPoint2();
180 void SetYPoint1();
181 void SetYPoint2();
183};
184
185#endif
Abstract superclass for all custom control widgets of mitk::USDevice classes.
Widget for b mode controls of ultrasound devices. This class handles the mitk::USControlInterfaceBMod...
Widget for b mode controls of ultrasound devices. This class handles the mitk::USControlInterfaceDopp...
Widget for probes controls of ultrasound devices. This class handles the mitk::USControlInterfaceProb...
UltrasoundSupport This plugin provides functionality to manage Ultrasound devices,...
QmitkUSAbstractCustomWidget * m_ControlCustomWidget
void CreateQtPartControl(QWidget *parent) override
mitk::USDevice::Pointer m_Device
QmitkUSControlsProbesWidget * m_ControlProbesWidget
std::vector< mitk::Image::Pointer > m_curOutput
QmitkUSControlsDopplerWidget * m_ControlDopplerWidget
void SetColormap(mitk::DataNode::Pointer node, mitk::LookupTable::LookupTableType type)
QmitkUSControlsBModeWidget * m_ControlBModeWidget
static const std::string VIEW_ID
void OnDeviceServiceEvent(const ctkServiceEvent event)
std::vector< mitk::DataNode::Pointer > m_Node
Ui::UltrasoundSupportControls * m_Controls
QList< ctkServiceReference > m_CustomWidgetServiceReference
void SetTimerIntervals(int intervalPipeline, int interval2D, int interval3D)
mitk::SlicedGeometry3D::Pointer m_OldGeometry
double ComputeSpacing(mitk::Point3D p1, mitk::Point3D p2, double distance)