CustusX  2023.01.05-dev+develop.0da12
An IGT application
cxElastixWidget.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 CXELASTIXWIDGET_H_
13 #define CXELASTIXWIDGET_H_
14 
16 #include "cxStringPropertyBase.h"
17 #include "cxFileSelectWidget.h"
18 #include "cxElastixManager.h"
19 #include "cxFilePreviewWidget.h"
20 #include "cxBoolProperty.h"
21 
22 class QSpinBox;
23 class QPushButton;
24 class QLabel;
25 class QLineEdit;
26 
27 namespace cx
28 {
29 typedef boost::shared_ptr<class FilePathProperty> FilePathPropertyPtr;
30 class TimedAlgorithmProgressBar;
31 
45 {
46 Q_OBJECT
47 public:
48  ElastixWidget(RegServicesPtr services, QWidget* parent = NULL);
49  virtual ~ElastixWidget();
50 
51 public slots:
52 
53 private slots:
54  void registerSlot();
55  void userParameterFileSelected(QString filename);
56  void elastixChangedSlot();
57  void toggleDetailsSlot();
58  void savePresetSlot();
59  void deletePresetSlot();
60 
61 protected:
62  virtual void prePaintEvent();
63 private:
64  void createUI();
65  QWidget* createOptionsWidget();
66  FilePathPropertyPtr getExecutable(QDomElement root);
67  void recurseParameterFolders(QString root, QStringList* retval);
68 
69  QPushButton* mRegisterButton;
70  ElastixManagerPtr mElastixManager;
71 
72  StringPropertyBasePtr mFixedImage;
73  StringPropertyBasePtr mMovingImage;
74  FileSelectWidget* mParameterFileWidget0;
75  FilePreviewWidget* mFilePreviewWidget;
76  cx::TimedAlgorithmProgressBar* mTimedAlgorithmProgressBar;
77  QWidget* mOptionsWidget;
78 };
79 
83 }//namespace cx
84 
85 
86 #endif /* CXELASTIXWIDGET_H_ */
Widget for interfacing to the ElastiX registration package.
virtual void prePaintEvent()
Show progress for a TimedBaseAlgorithm.
boost::shared_ptr< class StringPropertyBase > StringPropertyBasePtr
View a xml document.
ElastixWidget(RegServicesPtr services, QWidget *parent=NULL)
boost::shared_ptr< class RegServices > RegServicesPtr
Definition: cxRegServices.h:20
boost::shared_ptr< class FilePathProperty > FilePathPropertyPtr
boost::shared_ptr< ElastixManager > ElastixManagerPtr
Widget for displaying and selecting a single file.
Namespace for all CustusX production code.