v2.0.0
Loading...
Searching...
No Matches
triggerdetectionview.h
Go to the documentation of this file.
1//=============================================================================================================
20
21#ifndef TRIGGERDETECTIONVIEW_H
22#define TRIGGERDETECTIONVIEW_H
23
24//=============================================================================================================
25// INCLUDES
26//=============================================================================================================
27
28#include "../disp_global.h"
29#include "abstractview.h"
30
31//=============================================================================================================
32// QT INCLUDES
33//=============================================================================================================
34
35#include <QMap>
36
37#include <memory>
38
39//=============================================================================================================
40// EIGEN INCLUDES
41//=============================================================================================================
42
43//=============================================================================================================
44// FORWARD DECLARATIONS
45//=============================================================================================================
46
47namespace Ui
48{
49class TriggerDetectionViewWidget;
50}
51
52namespace FIFFLIB
53{
54class FiffInfo;
55}
56
57//=============================================================================================================
58// DEFINE NAMESPACE DISPLIB
59//=============================================================================================================
60
61namespace DISPLIB
62{
63
64//=============================================================================================================
65// DISPLIB FORWARD DECLARATIONS
66//=============================================================================================================
67
68//=============================================================================================================
77{
78 Q_OBJECT
79
80public:
81 typedef QSharedPointer<TriggerDetectionView> SPtr;
82 typedef QSharedPointer<const TriggerDetectionView> ConstSPtr;
83
84 //=========================================================================================================
92 TriggerDetectionView(const QString& sSettingsPath = "",
93 QWidget* parent = 0,
94 Qt::WindowFlags f = Qt::Widget);
95
96 //=========================================================================================================
101
102 //=========================================================================================================
108 void init(const QSharedPointer<FIFFLIB::FiffInfo> pFiffInfo);
109
110 //=========================================================================================================
117 void setNumberDetectedTriggersAndTypes(int totalNumberDetections,
118 const QMap<int, QList<QPair<int, double>>>& mapDetectedTriggers);
119
120 //=========================================================================================================
126 QString getSelectedStimChannel();
127
128 //=========================================================================================================
132 void saveSettings();
133
134 //=========================================================================================================
138 void loadSettings();
139
140 //=========================================================================================================
144 void clearView();
145
146protected:
147 //=========================================================================================================
153 void updateGuiMode(GuiMode mode);
154
155 //=========================================================================================================
162
163 //=========================================================================================================
168
169 //=========================================================================================================
175 void onRealTimeTriggerColorChanged(bool state);
176
177 //=========================================================================================================
183 void onRealTimeTriggerColorTypeChanged(const QString& value);
184
185 //=========================================================================================================
190
191 //=========================================================================================================
195 void onDetectTriggers();
196
197 std::unique_ptr<Ui::TriggerDetectionViewWidget> m_pUi;
198
199 QSharedPointer<FIFFLIB::FiffInfo> m_pFiffInfo;
200
201 QMap<double, QColor> m_qMapTriggerColor;
202
204
205signals:
206 //=========================================================================================================
211
212 //=========================================================================================================
216 void triggerInfoChanged(const QMap<double,
217 QColor>& value,
218 bool bActive,
219 const QString& sTriggerCh,
220 double dThreshold);
221
222 //=========================================================================================================
226 void detectTriggers(const QString& sChannelName,
227 double iThreshold);
228};
229} // NAMESPACE
230
231#endif // TRIGGERDETECTIONVIEW_H
Export macros and build-info hooks for the DISPLIB shared library.
#define DISPSHARED_EXPORT
Definition disp_global.h:38
Common base widget for every dockable Quick-Control settings panel in DISPLIB.
FIFF file I/O, in-memory data structures and high-level readers/writers.
2-D display widgets and visualisation helpers (charts, topography, colour maps).
AbstractView(QWidget *parent=0, Qt::WindowFlags f=Qt::Widget)
TriggerDetectionView(const QString &sSettingsPath="", QWidget *parent=0, Qt::WindowFlags f=Qt::Widget)
QMap< double, QColor > m_qMapTriggerColor
void setNumberDetectedTriggersAndTypes(int totalNumberDetections, const QMap< int, QList< QPair< int, double > > > &mapDetectedTriggers)
std::unique_ptr< Ui::TriggerDetectionViewWidget > m_pUi
QSharedPointer< FIFFLIB::FiffInfo > m_pFiffInfo
QSharedPointer< TriggerDetectionView > SPtr
QSharedPointer< const TriggerDetectionView > ConstSPtr
void onRealTimeTriggerColorTypeChanged(const QString &value)
void init(const QSharedPointer< FIFFLIB::FiffInfo > pFiffInfo)
void triggerInfoChanged(const QMap< double, QColor > &value, bool bActive, const QString &sTriggerCh, double dThreshold)
void updateProcessingMode(ProcessingMode mode)
void detectTriggers(const QString &sChannelName, double iThreshold)
Full FIFF measurement info: per-channel descriptors, sampling and filter setup, projectors,...
Definition fiff_info.h:90