Medical Imaging Interaction Toolkit  2025.12.02
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"
23 #include "mitkSlicedGeometry3D.h"
25 #include <QWidget>
26 
27 class MITKQTWIDGETSEXT_EXPORT QmitkSliceWidget : public QWidget, public Ui::QmitkSliceWidgetUi
28 {
29  Q_OBJECT
30 
31 public:
32  QmitkSliceWidget(QWidget *parent = nullptr, const char *name = nullptr, Qt::WindowFlags f = {});
33 
35 
36  QFrame *GetSelectionFrame();
37 
38  void UpdateGL();
39 
40  void mousePressEvent(QMouseEvent *e) override;
41 
42  void setPopUpEnabled(bool b);
43 
44  void SetDataStorage(mitk::StandaloneDataStorage::Pointer storage);
45 
47 
49 
51 
53 
55 
57 
59 
60 public slots:
61 
62  void SetData(mitk::DataStorage::SetOfObjects::ConstIterator it);
63 
64  void SetData(mitk::DataStorage::SetOfObjects::ConstIterator it, mitk::AnatomicalPlane view);
65 
66  void SetData(mitk::DataNode::Pointer node);
67 
68  void SetData(mitk::DataNode::Pointer node, mitk::AnatomicalPlane view);
69 
70  void InitWidget(mitk::AnatomicalPlane viewDirection);
71 
72  void wheelEvent(QWheelEvent *e) override;
73 
74  void ChangeView(QAction *val);
75 
76  void SetLevelWindowEnabled(bool enable);
77 
78 protected:
81 
82 private:
83  bool popUpEnabled;
84  mitk::VtkPropRenderer::Pointer m_Renderer;
85  mitk::SlicedGeometry3D::Pointer m_SlicedGeometry;
86  mitk::StandaloneDataStorage::Pointer m_DataStorage;
87 
88  QMenu *popUp;
89 };
90 
91 #endif
#define MITKQTWIDGETSEXT_EXPORT
MITK implementation of the QVTKWidget.
bool IsLevelWindowEnabled()
mitk::AnatomicalPlane m_View
void SetData(mitk::DataStorage::SetOfObjects::ConstIterator it)
void SetData(mitk::DataNode::Pointer node)
void setPopUpEnabled(bool b)
QFrame * GetSelectionFrame()
mitk::BaseController * GetController() const
void wheelEvent(QWheelEvent *e) override
QmitkSliceWidget(QWidget *parent=nullptr, const char *name=nullptr, Qt::WindowFlags f={})
QmitkRenderWindow * m_RenderWindow
void mousePressEvent(QMouseEvent *e) override
mitk::StandaloneDataStorage * GetDataStorage()
QmitkRenderWindow * GetRenderWindow()
void SetDataStorage(mitk::StandaloneDataStorage::Pointer storage)
mitk::SliceNavigationController * GetSliceNavigationController() const
void ChangeView(QAction *val)
mitk::CameraRotationController * GetCameraRotationController() const
QmitkSliceNavigationWidget * GetSliceNavigationWidget()
void SetData(mitk::DataNode::Pointer node, mitk::AnatomicalPlane view)
void SetData(mitk::DataStorage::SetOfObjects::ConstIterator it, mitk::AnatomicalPlane view)
void InitWidget(mitk::AnatomicalPlane viewDirection)
void SetLevelWindowEnabled(bool enable)
mitk::VtkPropRenderer * GetRenderer()
Baseclass for renderer slice-/camera-/time-control.
Controls the selection of the slice the associated BaseRenderer will display.
Data management class that handles 'was created by' relations.