v2.0.0
Loading...
Searching...
No Matches
rtsensorstreammanager.h
Go to the documentation of this file.
1//=============================================================================================================
19
20#ifndef RTSENSORSTREAMMANAGER_H
21#define RTSENSORSTREAMMANAGER_H
22
23//=============================================================================================================
24// INCLUDES
25//=============================================================================================================
26
27#include "../disp3D_global.h"
28
29#include <QObject>
30#include <QVector>
31#include <QMap>
32#include <QString>
33#include <Eigen/Core>
34#include <memory>
35
36//=============================================================================================================
37// FORWARD DECLARATIONS
38//=============================================================================================================
39
40namespace DISP3DLIB
41{
42
43class BrainSurface;
46
47//=============================================================================================================
57{
58 Q_OBJECT
59
60public:
61 //=========================================================================================================
67 explicit RtSensorStreamManager(QObject* parent = nullptr);
68
69 //=========================================================================================================
73 ~RtSensorStreamManager() override;
74
75 // ── Streaming control ──────────────────────────────────────────────
76
89 bool startStreaming(const QString& modality,
90 const SensorFieldMapper& fieldMapper,
91 const QMap<QString, std::shared_ptr<BrainSurface>>& surfaces);
92
94 void stopStreaming();
95
97 bool isStreaming() const
98 {
99 return m_isStreaming;
100 }
101
103 QString modality() const
104 {
105 return m_modality;
106 }
107
108 // ── Data input ─────────────────────────────────────────────────────
109
115 void pushData(const Eigen::VectorXf& data);
116
117 // ── Parameter control ──────────────────────────────────────────────
118
124 void setInterval(int msec);
125
131 void setLooping(bool enabled);
132
138 void setAverages(int numAvr);
139
145 void setColormap(const QString& name);
146
147signals:
148 //=========================================================================================================
156 void colorsAvailable(const QString& surfaceKey,
157 const QVector<uint32_t>& colors);
158
159private:
160 std::unique_ptr<RtSensorDataController> m_controller;
161 bool m_isStreaming = false;
162 QString m_modality;
163};
164
165} // namespace DISP3DLIB
166
167#endif // RTSENSORSTREAMMANAGER_H
Library export/import macros and namespace marker for the disp3D library.
#define DISP3DSHARED_EXPORT
3-D brain visualisation using the Qt RHI rendering backend.
Renderable cortical surface mesh with per-vertex color, curvature data, and GPU buffer management.
RtSensorStreamManager(QObject *parent=nullptr)
void colorsAvailable(const QString &surfaceKey, const QVector< uint32_t > &colors)
bool startStreaming(const QString &modality, const SensorFieldMapper &fieldMapper, const QMap< QString, std::shared_ptr< BrainSurface > > &surfaces)
Sensor-to-surface field mapper that interpolates MEG/EEG measurements onto cortical meshes and genera...
Controller for real-time sensor data streaming.