Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
QmitkBinaryThresholdToolGUI.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,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef QmitkBinaryThresholdToolGUI_h_Included
18 #define QmitkBinaryThresholdToolGUI_h_Included
19 
20 #include "QmitkToolGUI.h"
23 
24 #include <QDoubleSpinBox>
25 
26 class QSlider;
41 {
42  Q_OBJECT
43 
44 public:
46  itkFactorylessNewMacro(Self) itkCloneMacro(Self)
47 
48  void OnThresholdingIntervalBordersChanged(double lower, double upper, bool isFloat);
49  void OnThresholdingValueChanged(double current);
50 
51 signals:
52 
54  void thresholdAccepted();
55 
57  void thresholdCanceled();
58 
59 public slots:
60 
61 protected slots:
62 
63  void OnNewToolAssociated(mitk::Tool *);
64  void OnAcceptThresholdPreview();
65 
67  void OnSpinnerValueChanged();
68 
70  void OnSliderValueChanged(int value);
71 
72 protected:
74  virtual ~QmitkBinaryThresholdToolGUI();
75 
77  double SliderIntToDouble(int val);
78 
80  int DoubleToSliderInt(double val);
81 
82  QSlider *m_Slider;
83  QDoubleSpinBox *m_Spinner;
84 
86  bool m_isFloat;
87 
88  double m_RangeMin;
89  double m_RangeMax;
90  double m_Range;
91 
93  bool m_ChangingSlider, m_ChangingSpinner;
94 
96 };
97 
98 #endif
Base class of all tools used by mitk::ToolManager.
Definition: mitkTool.h:92
bool m_isFloat
is image float or int?
mitk::BinaryThresholdTool::Pointer m_BinaryThresholdTool
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:44
Base class for GUIs belonging to mitk::Tool classes.
Definition: QmitkToolGUI.h:36
GUI for mitk::BinaryThresholdTool.
#define MITKSEGMENTATIONUI_EXPORT