Fraxinus  22.09
An IGT application
cxVBWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 This file is part of CustusX, an Image Guided Therapy Application.
3 
4 Copyright (c) SINTEF Department of Medical Technology.
5 All rights reserved.
6 
7 CustusX is released under a BSD 3-Clause license.
8 
9 See Lisence.txt (https://github.com/SINTEFMedtek/CustusX/blob/master/License.txt) for details.
10 =========================================================================*/
11 
12 #ifndef CXVBWIDGET_H_
13 #define CXVBWIDGET_H_
14 
15 #include <QWidget>
16 
17 #include "ctkPluginContext.h"
18 
20 #include "cxMesh.h"
21 #include "cxVBcameraPath.h"
22 #include "org_custusx_virtualbronchoscopy_Export.h"
23 
24 
25 class QVBoxLayout;
26 class QDial;
27 class QSlider;
28 class QPushButton;
29 
30 namespace cx
31 {
32 
33 typedef boost::shared_ptr<class StringPropertySelectMesh> StringPropertySelectMeshPtr;
34 typedef boost::shared_ptr<class PatientStorage> PatientStoragePtr;
35 
44 class org_custusx_virtualbronchoscopy_EXPORT VBWidget : public QWidget
45 {
46  Q_OBJECT
47 public:
48  VBWidget(VisServicesPtr services, QWidget *parent = 0);
49  virtual ~VBWidget();
50  void setRouteToTarget(QString uid);
51  void setRoutePositions(std::vector< Eigen::Vector3d > routePositions);
52  void setCameraRotationAlongRoute(std::vector< double > cameraRotations);
53 
54 protected:
55  QString defaultWhatsThis() const;
56  QVBoxLayout* mVerticalLayout;
57  QSlider* mPlaybackSlider;
58  QDial* mRotateDial;
59  QDial* mViewDial;
60  QPushButton* mResetEndoscopeButton;
63 
64  StringPropertySelectMeshPtr mRouteToTarget;
68 
69  void enableControls(bool enable);
70 
71  PatientStoragePtr mStorage;
72 
73 signals:
74  void cameraPathChanged(MeshPtr pathMesh);
75 
76 private slots:
77  void inputChangedSlot();
78  void resetEndoscopeSlot();
79  void automaticRotationSlot();
80  void updateRotationDialSlot(int value);
81 protected slots:
82  virtual void keyPressEvent(QKeyEvent* event);
83 };
84 
85 } /* namespace cx */
86 
87 #endif /* CXVBWIDGET_H_ */
boost::shared_ptr< class VisServices > VisServicesPtr
Definition: cxMainWindow.h:40
QDial * mViewDial
Definition: cxVBWidget.h:59
QPalette mAutomaticRotationButtonBackgroundColor
Definition: cxVBWidget.h:62
PatientStoragePtr mStorage
Definition: cxVBWidget.h:71
StringPropertySelectMeshPtr mRouteToTarget
Definition: cxVBWidget.h:64
QDial * mRotateDial
Definition: cxVBWidget.h:58
bool mControlsEnabled
Definition: cxVBWidget.h:66
QSlider * mPlaybackSlider
Definition: cxVBWidget.h:57
QPushButton * mUseAutomaticRotationButton
Definition: cxVBWidget.h:61
boost::shared_ptr< class PatientStorage > PatientStoragePtr
Definition: cxVBWidget.h:34
QVBoxLayout * mVerticalLayout
Definition: cxVBWidget.h:56
CXVBcameraPath * mCameraPath
Definition: cxVBWidget.h:65
QPushButton * mResetEndoscopeButton
Definition: cxVBWidget.h:60
boost::shared_ptr< class Mesh > MeshPtr
boost::shared_ptr< class StringPropertySelectMesh > StringPropertySelectMeshPtr
bool mAutomaticRotation
Definition: cxVBWidget.h:67
Namespace for all CustusX production code.