Medical Imaging Interaction Toolkit  2018.4.99-389bf124
Medical Imaging Interaction Toolkit
QmitkSliceWidget.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef QMITKSLICEWIDGET_H_
14 #define QMITKSLICEWIDGET_H_
15 
17 #include "ui_QmitkSliceWidget.h"
18 
19 #include "QmitkRenderWindow.h"
20 #include "mitkDataStorage.h"
22 #include "mitkSlicedGeometry3D.h"
24 #include <QWidget>
25 
26 class MITKQTWIDGETSEXT_EXPORT QmitkSliceWidget : public QWidget, public Ui::QmitkSliceWidgetUi
27 {
28  Q_OBJECT
29 
30 public:
31  QmitkSliceWidget(QWidget *parent = nullptr, const char *name = nullptr, Qt::WindowFlags f = nullptr);
32 
33  mitk::VtkPropRenderer *GetRenderer();
34 
35  QFrame *GetSelectionFrame();
36 
37  void UpdateGL();
38 
39  void mousePressEvent(QMouseEvent *e) override;
40 
41  void setPopUpEnabled(bool b);
42 
43  void SetDataStorage(mitk::StandaloneDataStorage::Pointer storage);
44 
45  mitk::StandaloneDataStorage *GetDataStorage();
46 
47  QmitkSliderNavigatorWidget *GetNavigatorWidget();
48 
49  bool IsLevelWindowEnabled();
50 
51  QmitkRenderWindow *GetRenderWindow();
52 
53  mitk::SliceNavigationController *GetSliceNavigationController() const;
54 
55  mitk::CameraRotationController *GetCameraRotationController() const;
56 
57  mitk::BaseController *GetController() const;
58 
59 public slots:
60 
61  void SetData(mitk::DataStorage::SetOfObjects::ConstIterator it);
62 
63  void SetData(mitk::DataStorage::SetOfObjects::ConstIterator it, mitk::SliceNavigationController::ViewDirection view);
64 
65  void SetData(mitk::DataNode::Pointer node);
66 
68 
69  void InitWidget(mitk::SliceNavigationController::ViewDirection viewDirection);
70 
71  void wheelEvent(QWheelEvent *e) override;
72 
73  void ChangeView(QAction *val);
74 
75  void SetLevelWindowEnabled(bool enable);
76 
77 protected:
80 
81 private:
82  bool popUpEnabled;
84  mitk::SlicedGeometry3D::Pointer m_SlicedGeometry;
86 
87  QMenu *popUp;
88 };
89 
90 #endif
Data management class that handles &#39;was created by&#39; relations.
Baseclass for renderer slice-/camera-control.
#define MITKQTWIDGETSEXT_EXPORT
Controls the selection of the slice the associated BaseRenderer will display.
mitk::SliceNavigationController::ViewDirection m_View
mitk::DataStorage::Pointer m_DataStorage
ViewDirection
Possible view directions, Original will uses the PlaneGeometry instances in a SlicedGeometry3D provid...
MITK implementation of the QVTKWidget.
QmitkRenderWindow * m_RenderWindow