MNE-CPP  0.1.9
A Framework for Electrophysiology
sensordatatreeitem.cpp
Go to the documentation of this file.
1 //=============================================================================================================
36 //=============================================================================================================
37 // INCLUDES
38 //=============================================================================================================
39 
40 #include "sensordatatreeitem.h"
41 #include "../common/metatreeitem.h"
42 #include "../../workers/rtSensorData/rtsensordatacontroller.h"
43 #include "../common/gpuinterpolationitem.h"
44 #include "../common/abstractmeshtreeitem.h"
45 #include "../../3dhelpers/custommesh.h"
46 #include "../../materials/pervertexphongalphamaterial.h"
47 
48 #include <mne/mne_bem.h>
49 
50 //=============================================================================================================
51 // QT INCLUDES
52 //=============================================================================================================
53 
54 #include <QVector3D>
55 #include <QGeometryRenderer>
56 #include <Qt3DCore/QTransform>
57 
58 //=============================================================================================================
59 // EIGEN INCLUDES
60 //=============================================================================================================
61 
62 #include <Eigen/Core>
63 
64 //=============================================================================================================
65 // USED NAMESPACES
66 //=============================================================================================================
67 
68 using namespace Eigen;
69 using namespace FIFFLIB;
70 using namespace DISP3DLIB;
71 using namespace MNELIB;
72 
73 //=============================================================================================================
74 // DEFINE GLOBAL METHODS
75 //=============================================================================================================
76 
77 //=============================================================================================================
78 // DEFINE MEMBER METHODS
79 //=============================================================================================================
80 
81 SensorDataTreeItem::SensorDataTreeItem(int iType,
82  const QString &text,
83  bool bUseGPU)
84 : AbstractTreeItem(iType,text)
85 , m_bIsDataInit(false)
86 , m_bUseGPU(bUseGPU)
87 , m_pSensorRtDataWorkController(new RtSensorDataController())
88 {
89  initItem();
90 }
91 
92 //=============================================================================================================
93 
95 {
96  m_pSensorRtDataWorkController->deleteLater();
97 }
98 
99 //=============================================================================================================
100 
102  const FiffInfo &fiffInfo,
103  const QString &sSensorType,
104  Qt3DCore::QEntity* p3DEntityParent)
105 {
106  if(m_bIsDataInit == true) {
107  qDebug("SensorDataTreeItem::initData - Item is already initialized");
108  }
109 
110  this->setData(0, Data3DTreeModelItemRoles::Data);
111 
112  // map passed sensor type string to fiff constant
113  fiff_int_t sensorTypeFiffConstant;
114  if (sSensorType.toStdString() == "MEG") {
115  sensorTypeFiffConstant = FIFFV_MEG_CH;
116  } else if (sSensorType.toStdString() == "EEG") {
117  sensorTypeFiffConstant = FIFFV_EEG_CH;
118  } else {
119  qDebug() << "SensorDataTreeItem::initData - unknown sensor type. Returning ...";
120  return;
121  }
122 
123  //Fill QVector with the right sensor positions, exclude bad channels
124  //Only take EEG with V as unit or MEG magnetometers with T as unit
125  QVector<Vector3f> vecSensorPos;
126  m_iUsedSensors.clear();
127  int iCounter = 0;
128  for(const FiffChInfo &info : fiffInfo.chs) {
129  if(info.kind == sensorTypeFiffConstant &&
130  (info.unit == FIFF_UNIT_T || info.unit == FIFF_UNIT_V)) {
131  vecSensorPos.push_back(info.chpos.r0);
132 
133  //save the number of the sensor
134  m_iUsedSensors.push_back(iCounter);
135  }
136  iCounter++;
137  }
138 
139  //Create bad channel idx list
140  for(const QString &bad : fiffInfo.bads) {
141  m_iSensorsBad.push_back(fiffInfo.ch_names.indexOf(bad));
142  }
143 
144  //Create InterpolationItems for CPU or GPU usage
145  if(m_bUseGPU) {
147  m_pInterpolationItemGPU = new GpuInterpolationItem(p3DEntityParent,
148  Data3DTreeModelItemTypes::GpuInterpolationItem,
149  QStringLiteral("3D Plot"));
150 
151  m_pInterpolationItemGPU->initData(bemSurface.rr,
152  bemSurface.nn,
153  bemSurface.tris);
154 
155  QList<QStandardItem*> list;
156  list << m_pInterpolationItemGPU;
157  list << new QStandardItem(m_pInterpolationItemGPU->toolTip());
158  this->appendRow(list);
159  }
160 
161  m_pSensorRtDataWorkController->setStreamSmoothedData(false);
162 
165 
168  } else {
170  m_pInterpolationItemCPU = new AbstractMeshTreeItem(p3DEntityParent,
171  Data3DTreeModelItemTypes::AbstractMeshItem,
172  QStringLiteral("3D Plot"));
173 
174  //Create color from curvature information with default gyri and sulcus colors
175  MatrixX4f matVertColor = AbstractMeshTreeItem::createVertColor(bemSurface.rr.rows());
176 
177  m_pInterpolationItemCPU->setMeshData(bemSurface.rr,
178  bemSurface.nn,
179  bemSurface.tris,
180  matVertColor,
181  Qt3DRender::QGeometryRenderer::Triangles);
182 
183  QList<QStandardItem*> list;
184  list << m_pInterpolationItemCPU;
185  list << new QStandardItem(m_pInterpolationItemCPU->toolTip());
186  this->appendRow(list);
187 
188  //Set material to enable sorting
189  QPointer<PerVertexPhongAlphaMaterial> pBemMaterial = new PerVertexPhongAlphaMaterial(true);
190  m_pInterpolationItemCPU->setMaterial(pBemMaterial);
191  }
192 
195  }
196 
197  //Setup worker
198  m_pSensorRtDataWorkController->setInterpolationInfo(bemSurface.rr,
199  bemSurface.neighbor_vert,
200  vecSensorPos,
201  fiffInfo,
202  sensorTypeFiffConstant);
203 
204  //Init complete
205  m_bIsDataInit = true;
206 }
207 
208 //=============================================================================================================
209 
210 void SensorDataTreeItem::addData(const MatrixXd &tSensorData)
211 {
212  if(!m_bIsDataInit) {
213  qDebug() << "SensorDataTreeItem::addData - item has not been initialized yet!";
214  return;
215  }
216 
217  //if more data then needed is provided
218  const int iSensorSize = m_iUsedSensors.size();
219  if(tSensorData.rows() > iSensorSize)
220  {
221  MatrixXd dSmallSensorData(iSensorSize, tSensorData.cols());
222  for(int i = 0 ; i < iSensorSize; ++i)
223  {
224  //Set bad channels to zero so that the data does not corrupt while the bad channels vertex is weighted by surrounding sensors
225  if(m_iSensorsBad.contains(m_iUsedSensors[i])) {
226  dSmallSensorData.row(i).setZero();
227  } else {
228  dSmallSensorData.row(i) = tSensorData.row(m_iUsedSensors[i]);
229  }
230  }
231  //Set new data into item's data.
232  QVariant data;
233  data.setValue(dSmallSensorData);
234  this->setData(data, Data3DTreeModelItemRoles::Data);
235 
236  //Add data to worker
237  m_pSensorRtDataWorkController->addData(dSmallSensorData);
238  }
239  else
240  {
241  //Set bad channels to zero
242  MatrixXd dSmallSensorData = tSensorData;
243  for(int i = 0 ; i < dSmallSensorData.rows(); ++i)
244  {
245  if(m_iSensorsBad.contains(m_iUsedSensors[i])) {
246  dSmallSensorData.row(i).setZero();
247  }
248  }
249 
250  //Set new data into item's data.
251  QVariant data;
252  data.setValue(dSmallSensorData);
253  this->setData(data, Data3DTreeModelItemRoles::Data);
254 
255  //Add data to worker
256  m_pSensorRtDataWorkController->addData(dSmallSensorData);
257  }
258 }
259 
260 //=============================================================================================================
261 
263 {
264  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::LoopedStreaming);
265 
266  for(int i = 0; i < lItems.size(); i++) {
267  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
268  pAbstractItem->setCheckState(bState == true ? Qt::Checked : Qt::Unchecked);
269  QVariant data;
270  data.setValue(bState);
271  pAbstractItem->setData(data, MetaTreeItemRoles::LoopedStreaming);
272  }
273  }
274 }
275 
276 //=============================================================================================================
277 
279 {
280  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::StreamStatus);
281 
282  for(int i = 0; i < lItems.size(); i++) {
283  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
284  pAbstractItem->setCheckState(bState == true ? Qt::Checked : Qt::Unchecked);
285  QVariant data;
286  data.setValue(bState);
287  pAbstractItem->setData(data, MetaTreeItemRoles::StreamStatus);
288  }
289  }
290 }
291 
292 //=============================================================================================================
293 
295 {
296  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::StreamingTimeInterval);
297 
298  for(int i = 0; i < lItems.size(); i++) {
299  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
300  QVariant data;
301  data.setValue(iMSec);
302  pAbstractItem->setData(data, MetaTreeItemRoles::StreamingTimeInterval);
303  pAbstractItem->setData(data, Qt::DisplayRole);
304  }
305  }
306 }
307 
308 //=============================================================================================================
309 
310 void SensorDataTreeItem::setNumberAverages(int iNumberAverages)
311 {
312  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::NumberAverages);
313 
314  for(int i = 0; i < lItems.size(); i++) {
315  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
316  QVariant data;
317  data.setValue(iNumberAverages);
318  pAbstractItem->setData(data, MetaTreeItemRoles::NumberAverages);
319  pAbstractItem->setData(data, Qt::DisplayRole);
320  }
321  }
322 }
323 
324 //=============================================================================================================
325 
326 void SensorDataTreeItem::setColormapType(const QString& sColormap)
327 {
328  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::ColormapType);
329 
330  for(int i = 0; i < lItems.size(); i++) {
331  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
332  QVariant data;
333  data.setValue(sColormap);
334  pAbstractItem->setData(data, MetaTreeItemRoles::ColormapType);
335  pAbstractItem->setData(data, Qt::DisplayRole);
336  }
337  }
338 }
339 
340 //=============================================================================================================
341 
342 void SensorDataTreeItem::setThresholds(const QVector3D& vecThresholds)
343 {
344  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::DataThreshold);
345 
346  for(int i = 0; i < lItems.size(); i++) {
347  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
348  QVariant data;
349  data.setValue(vecThresholds);
350  pAbstractItem->setData(data, MetaTreeItemRoles::DataThreshold);
351 
352  QString sTemp = QString("%1,%2,%3").arg(vecThresholds.x()).arg(vecThresholds.y()).arg(vecThresholds.z());
353  data.setValue(sTemp);
354  pAbstractItem->setData(data, Qt::DisplayRole);
355  }
356  }
357 }
358 
359 //=============================================================================================================
360 
362 {
363  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::CancelDistance);
364 
365  for(int i = 0; i < lItems.size(); i++) {
366  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
367  QVariant data;
368  data.setValue(dCancelDist);
369  pAbstractItem->setData(data, MetaTreeItemRoles::CancelDistance);
370  pAbstractItem->setData(data, Qt::DisplayRole);
371  }
372  }
373 }
374 
375 //=============================================================================================================
376 
377 void SensorDataTreeItem::setInterpolationFunction(const QString &sInterpolationFunction)
378 {
379  QList<QStandardItem*> lItems = this->findChildren(MetaTreeItemTypes::InterpolationFunction);
380 
381  for(int i = 0; i < lItems.size(); i++) {
382  if(MetaTreeItem* pAbstractItem = dynamic_cast<MetaTreeItem*>(lItems.at(i))) {
383  QVariant data;
384  data.setValue(sInterpolationFunction);
385  pAbstractItem->setData(data, MetaTreeItemRoles::InterpolationFunction);
386  pAbstractItem->setData(data, Qt::DisplayRole);
387  }
388  }
389 }
390 
391 //=============================================================================================================
392 
393 void SensorDataTreeItem::setSFreq(const double dSFreq)
394 {
396  m_pSensorRtDataWorkController->setSFreq(dSFreq);
397  }
398 }
399 
400 //=============================================================================================================
401 
403 {
405  //Create bad channel idx list
406  m_iSensorsBad.clear();
407  for(const QString &bad : info.bads) {
408  m_iSensorsBad.push_back(info.ch_names.indexOf(bad));
409  }
410 
411  //qDebug() << "SensorDataTreeItem::setBadChannels - m_iSensorsBad" << m_iSensorsBad;
412  m_pSensorRtDataWorkController->setBadChannels(info);
413  }
414 }
415 
416 //=============================================================================================================
417 
418 void SensorDataTreeItem::setTransform(const Qt3DCore::QTransform& transform)
419 {
421  m_pInterpolationItemGPU->setTransform(transform);
422  }
423 
425  m_pInterpolationItemCPU->setTransform(transform);
426  }
427 }
428 
429 //=============================================================================================================
430 
431 void SensorDataTreeItem::setTransform(const FiffCoordTrans& transform, bool bApplyInverse)
432 {
434  m_pInterpolationItemGPU->setTransform(transform, bApplyInverse);
435  }
436 
438  m_pInterpolationItemCPU->setTransform(transform, bApplyInverse);
439  }
440 }
441 
442 //=============================================================================================================
443 
444 void SensorDataTreeItem::applyTransform(const Qt3DCore::QTransform& transform)
445 {
447  m_pInterpolationItemGPU->applyTransform(transform);
448  }
449 
451  m_pInterpolationItemCPU->applyTransform(transform);
452  }
453 }
454 
455 //=============================================================================================================
456 
457 void SensorDataTreeItem::applyTransform(const FiffCoordTrans& transform, bool bApplyInverse)
458 {
460  m_pInterpolationItemGPU->applyTransform(transform, bApplyInverse);
461  }
462 
464  m_pInterpolationItemCPU->applyTransform(transform, bApplyInverse);
465  }
466 }
467 
468 //=============================================================================================================
469 
471 {
472  this->setEditable(false);
473  this->setCheckable(true);
474  this->setCheckState(Qt::Checked);
475  this->setToolTip("Sensor Data item");
476 
477  //Add items
478  QList<QStandardItem*> list;
479  QVariant data;
480 
481  MetaTreeItem* pItemStreamStatus = new MetaTreeItem(MetaTreeItemTypes::StreamStatus, "Stream data on/off");
482  list << pItemStreamStatus;
483  list << new QStandardItem(pItemStreamStatus->toolTip());
484  this->appendRow(list);
485  pItemStreamStatus->setCheckable(true);
486  pItemStreamStatus->setEditable(false);
487  pItemStreamStatus->setCheckState(Qt::Unchecked);
488  connect(pItemStreamStatus, &MetaTreeItem::checkStateChanged,
490 
491  data.setValue(false);
492  pItemStreamStatus->setData(data, MetaTreeItemRoles::StreamStatus);
493 
494  MetaTreeItem* pItemColormapType = new MetaTreeItem(MetaTreeItemTypes::ColormapType, "Hot");
495  list.clear();
496  list << pItemColormapType;
497  list << new QStandardItem(pItemColormapType->toolTip());
498  this->appendRow(list);
499  data.setValue(QString("Hot"));
500  pItemColormapType->setData(data, MetaTreeItemRoles::ColormapType);
501  connect(pItemColormapType, &MetaTreeItem::dataChanged,
503 
504  MetaTreeItem* pItemThreshold = new MetaTreeItem(MetaTreeItemTypes::DataThreshold, "0.0, 0.5,10.0");
505  list.clear();
506  list << pItemThreshold;
507  list << new QStandardItem(pItemThreshold->toolTip());
508  this->appendRow(list);
509  data.setValue(QVector3D(0.0,5.5,15));
510  pItemThreshold->setData(data, MetaTreeItemRoles::DataThreshold);
511  connect(pItemThreshold, &MetaTreeItem::dataChanged,
513 
514  MetaTreeItem *pItemStreamingInterval = new MetaTreeItem(MetaTreeItemTypes::StreamingTimeInterval, "17");
515  list.clear();
516  list << pItemStreamingInterval;
517  list << new QStandardItem(pItemStreamingInterval->toolTip());
518  this->appendRow(list);
519  data.setValue(17);
520  pItemStreamingInterval->setData(data, MetaTreeItemRoles::StreamingTimeInterval);
521  connect(pItemStreamingInterval, &MetaTreeItem::dataChanged,
523 
524  MetaTreeItem *pItemLoopedStreaming = new MetaTreeItem(MetaTreeItemTypes::LoopedStreaming, "Looping on/off");
525  pItemLoopedStreaming->setCheckable(true);
526  pItemLoopedStreaming->setCheckState(Qt::Checked);
527  list.clear();
528  list << pItemLoopedStreaming;
529  list << new QStandardItem(pItemLoopedStreaming->toolTip());
530  this->appendRow(list);
531  connect(pItemLoopedStreaming, &MetaTreeItem::checkStateChanged,
533 
534  MetaTreeItem *pItemAveragedStreaming = new MetaTreeItem(MetaTreeItemTypes::NumberAverages, "17");
535  list.clear();
536  list << pItemAveragedStreaming;
537  list << new QStandardItem(pItemAveragedStreaming->toolTip());
538  this->appendRow(list);
539  data.setValue(1);
540  pItemAveragedStreaming->setData(data, MetaTreeItemRoles::NumberAverages);
541  connect(pItemAveragedStreaming, &MetaTreeItem::dataChanged,
543 
544  MetaTreeItem *pItemCancelDistance = new MetaTreeItem(MetaTreeItemTypes::CancelDistance, "0.05");
545  list.clear();
546  list << pItemCancelDistance;
547  list << new QStandardItem(pItemCancelDistance->toolTip());
548  this->appendRow(list);
549  data.setValue(0.05);
550  pItemCancelDistance->setData(data, MetaTreeItemRoles::CancelDistance);
551  connect(pItemCancelDistance, &MetaTreeItem::dataChanged,
553 
554  MetaTreeItem* pInterpolationFunction = new MetaTreeItem(MetaTreeItemTypes::InterpolationFunction, "Cubic");
555  list.clear();
556  list << pInterpolationFunction;
557  list << new QStandardItem(pInterpolationFunction->toolTip());
558  this->appendRow(list);
559  data.setValue(QString("Cubic"));
560  pInterpolationFunction->setData(data, MetaTreeItemRoles::InterpolationFunction);
561  connect(pInterpolationFunction, &MetaTreeItem::dataChanged,
563 }
564 
565 //=============================================================================================================
566 
567 void SensorDataTreeItem::onNewInterpolationMatrixAvailable(QSharedPointer<SparseMatrix<float> > pMatInterpolationMatrixLeftHemi)
568 {
570  {
571  m_pInterpolationItemGPU->setInterpolationMatrix(pMatInterpolationMatrixLeftHemi);
572  }
573 }
574 
575 //=============================================================================================================
576 
577 void SensorDataTreeItem::onNewRtRawDataAvailable(const VectorXd &vecDataVector)
578 {
580  {
581  m_pInterpolationItemGPU->addNewRtData(vecDataVector.cast<float>());
582  }
583 }
584 
585 //=============================================================================================================
586 
587 void SensorDataTreeItem::onNewRtSmoothedDataAvailable(const MatrixX4f &matColorMatrix)
588 {
590  {
591  m_pInterpolationItemCPU->setVertColor(matColorMatrix);
592  }
593 }
594 
595 //=============================================================================================================
596 
597 void SensorDataTreeItem::onStreamingStateChanged(const Qt::CheckState &checkState)
598 {
600  if(checkState == Qt::Checked) {
601  m_pSensorRtDataWorkController->setStreamingState(true);
602  } else if(checkState == Qt::Unchecked) {
603  m_pSensorRtDataWorkController->setStreamingState(false);
604  }
605  }
606 }
607 
608 //=============================================================================================================
609 
610 void SensorDataTreeItem::onColormapTypeChanged(const QVariant &sColormapType)
611 {
612  if(sColormapType.canConvert<QString>()) {
613  if(m_bUseGPU) {
615  m_pInterpolationItemGPU->setColormapType(sColormapType.toString());
616  }
617  } else {
619  m_pSensorRtDataWorkController->setColormapType(sColormapType.toString());
620  }
621  }
622  }
623 }
624 
625 //=============================================================================================================
626 
627 void SensorDataTreeItem::onTimeIntervalChanged(const QVariant &iMSec)
628 {
629  if(iMSec.canConvert<int>()) {
631  m_pSensorRtDataWorkController->setTimeInterval(iMSec.toInt());
632  }
633  }
634 }
635 
636 //=============================================================================================================
637 
638 void SensorDataTreeItem::onDataThresholdChanged(const QVariant &vecThresholds)
639 {
640  if(vecThresholds.canConvert<QVector3D>()) {
641  if(m_bUseGPU) {
643  m_pInterpolationItemGPU->setThresholds(vecThresholds.value<QVector3D>());
644  }
645  } else {
647  m_pSensorRtDataWorkController->setThresholds(vecThresholds.value<QVector3D>());
648  }
649  }
650  }
651 }
652 
653 //=============================================================================================================
654 
655 void SensorDataTreeItem::onLoopStateChanged(const Qt::CheckState &checkState)
656 {
658  if(checkState == Qt::Checked) {
659  m_pSensorRtDataWorkController->setLoopState(true);
660  } else if(checkState == Qt::Unchecked) {
661  m_pSensorRtDataWorkController->setLoopState(false);
662  }
663  }
664 }
665 
666 //=============================================================================================================
667 
668 void SensorDataTreeItem::onNumberAveragesChanged(const QVariant &iNumAvr)
669 {
670  if(iNumAvr.canConvert<int>()) {
672  m_pSensorRtDataWorkController->setNumberAverages(iNumAvr.toInt());
673  }
674  }
675 }
676 
677 //=============================================================================================================
678 
679 void SensorDataTreeItem::onCancelDistanceChanged(const QVariant &dCancelDist)
680 {
681  if(dCancelDist.canConvert<double>())
682  {
684  m_pSensorRtDataWorkController->setCancelDistance(dCancelDist.toDouble());
685  }
686  }
687 }
688 
689 //=============================================================================================================
690 
691 void SensorDataTreeItem::onInterpolationFunctionChanged(const QVariant &sInterpolationFunction)
692 {
693  if(sInterpolationFunction.canConvert<QString>())
694  {
696  m_pSensorRtDataWorkController->setInterpolationFunction(sInterpolationFunction.toString());
697  }
698  }
699 }
DISP3DLIB::SensorDataTreeItem::setSFreq
virtual void setSFreq(const double dSFreq)
Definition: sensordatatreeitem.cpp:393
sensordatatreeitem.h
DISP3DLIB::SensorDataTreeItem::onCancelDistanceChanged
virtual void onCancelDistanceChanged(const QVariant &dCancelDist)
Definition: sensordatatreeitem.cpp:679
DISP3DLIB::SensorDataTreeItem::setBadChannels
virtual void setBadChannels(const FIFFLIB::FiffInfo &info)
Definition: sensordatatreeitem.cpp:402
MNELIB::MNEBemSurface::neighbor_vert
QVector< QVector< int > > neighbor_vert
Definition: mne_bem_surface.h:170
FIFFLIB::FiffInfo
FIFF measurement file information.
Definition: fiff_info.h:84
MNELIB::MNEBemSurface::tris
Eigen::MatrixX3i tris
Definition: mne_bem_surface.h:165
FIFFLIB::FiffChPos::r0
Eigen::Vector3f r0
Definition: fiff_ch_pos.h:112
DISP3DLIB::SensorDataTreeItem::onTimeIntervalChanged
virtual void onTimeIntervalChanged(const QVariant &iMSec)
Definition: sensordatatreeitem.cpp:627
DISP3DLIB::SensorDataTreeItem::onNewRtRawDataAvailable
virtual void onNewRtRawDataAvailable(const Eigen::VectorXd &vecDataVector)
Definition: sensordatatreeitem.cpp:577
DISP3DLIB::SensorDataTreeItem::onNumberAveragesChanged
virtual void onNumberAveragesChanged(const QVariant &iNumAvr)
Definition: sensordatatreeitem.cpp:668
DISP3DLIB::PerVertexPhongAlphaMaterial
PerVertexPhongAlphaMaterial is provides a Qt3D material with own shader support.
Definition: pervertexphongalphamaterial.h:80
DISP3DLIB::RtSensorDataController::newInterpolationMatrixAvailable
void newInterpolationMatrixAvailable(QSharedPointer< Eigen::SparseMatrix< float > > pMatInterpolationMatrix)
DISP3DLIB::SensorDataTreeItem::onInterpolationFunctionChanged
virtual void onInterpolationFunctionChanged(const QVariant &sInterpolationFunction)
Definition: sensordatatreeitem.cpp:691
DISP3DLIB::MetaTreeItem::dataChanged
void dataChanged(const QVariant &data)
FIFFLIB::FiffInfoBase::bads
QStringList bads
Definition: fiff_info_base.h:220
DISP3DLIB::AbstractTreeItem
Provides the basic tree item.
Definition: abstracttreeitem.h:76
MNELIB::MNEBemSurface::rr
Eigen::MatrixX3f rr
Definition: mne_bem_surface.h:163
DISP3DLIB::SensorDataTreeItem::setInterpolationFunction
virtual void setInterpolationFunction(const QString &sInterpolationFunction)
Definition: sensordatatreeitem.cpp:377
DISP3DLIB::SensorDataTreeItem::addData
virtual void addData(const Eigen::MatrixXd &tSensorData)
Definition: sensordatatreeitem.cpp:210
DISP3DLIB::AbstractTreeItem::setData
void setData(const QVariant &value, int role=Qt::UserRole+1)
Definition: abstracttreeitem.cpp:78
FIFFLIB::FiffChInfo::unit
fiff_int_t unit
Definition: fiff_ch_info.h:125
DISP3DLIB::SensorDataTreeItem::m_bIsDataInit
bool m_bIsDataInit
Definition: sensordatatreeitem.h:361
DISP3DLIB::SensorDataTreeItem::m_bUseGPU
bool m_bUseGPU
Definition: sensordatatreeitem.h:362
DISP3DLIB::SensorDataTreeItem::~SensorDataTreeItem
virtual ~SensorDataTreeItem()
Definition: sensordatatreeitem.cpp:94
MNELIB::MNEBemSurface::nn
Eigen::MatrixX3f nn
Definition: mne_bem_surface.h:164
DISP3DLIB::RtSensorDataController::newRtRawDataAvailable
void newRtRawDataAvailable(const Eigen::VectorXd &vecDataVector)
DISP3DLIB::SensorDataTreeItem::setTransform
virtual void setTransform(const Qt3DCore::QTransform &transform)
Definition: sensordatatreeitem.cpp:418
DISP3DLIB::SensorDataTreeItem::setThresholds
virtual void setThresholds(const QVector3D &vecThresholds)
Definition: sensordatatreeitem.cpp:342
DISP3DLIB::SensorDataTreeItem::initData
virtual void initData(const MNELIB::MNEBemSurface &tBemSurface, const FIFFLIB::FiffInfo &tFiffInfo, const QString &sSensorType, Qt3DCore::QEntity *p3DEntityParent)
Definition: sensordatatreeitem.cpp:101
DISP3DLIB::SensorDataTreeItem::m_pSensorRtDataWorkController
QPointer< RtSensorDataController > m_pSensorRtDataWorkController
Definition: sensordatatreeitem.h:367
DISP3DLIB::RtSensorDataController::newRtSmoothedDataAvailable
void newRtSmoothedDataAvailable(const Eigen::MatrixX4f &matColorMatrix)
DISP3DLIB::AbstractTreeItem::findChildren
QList< QStandardItem * > findChildren(int type)
Definition: abstracttreeitem.cpp:112
DISP3DLIB::MetaTreeItem
Provides a generic brain tree item.
Definition: metatreeitem.h:74
DISP3DLIB::SensorDataTreeItem::setNumberAverages
virtual void setNumberAverages(int iNumberAverages)
Definition: sensordatatreeitem.cpp:310
FIFFLIB::FiffChInfo
Channel info descriptor.
Definition: fiff_ch_info.h:74
FIFFLIB::FiffInfoBase::chs
QList< FiffChInfo > chs
Definition: fiff_info_base.h:223
DISP3DLIB::AbstractMeshTreeItem
Provides a generic mesh tree item.
Definition: abstractmeshtreeitem.h:90
mne_bem.h
MNEBem class declaration.
DISP3DLIB::SensorDataTreeItem::applyTransform
virtual void applyTransform(const Qt3DCore::QTransform &transform)
Definition: sensordatatreeitem.cpp:444
DISP3DLIB::SensorDataTreeItem::onNewRtSmoothedDataAvailable
virtual void onNewRtSmoothedDataAvailable(const Eigen::MatrixX4f &matColorMatrix)
Definition: sensordatatreeitem.cpp:587
DISP3DLIB::SensorDataTreeItem::onColormapTypeChanged
virtual void onColormapTypeChanged(const QVariant &sColormapType)
Definition: sensordatatreeitem.cpp:610
FIFFLIB::FiffInfoBase::ch_names
QStringList ch_names
Definition: fiff_info_base.h:224
DISP3DLIB::SensorDataTreeItem::m_iSensorsBad
QVector< int > m_iSensorsBad
Definition: sensordatatreeitem.h:365
DISP3DLIB::SensorDataTreeItem::onNewInterpolationMatrixAvailable
virtual void onNewInterpolationMatrixAvailable(QSharedPointer< Eigen::SparseMatrix< float > > pMatInterpolationMatrixLeftHemi)
Definition: sensordatatreeitem.cpp:567
DISP3DLIB::SensorDataTreeItem::setCancelDistance
virtual void setCancelDistance(double dCancelDist)
Definition: sensordatatreeitem.cpp:361
DISP3DLIB::SensorDataTreeItem::setLoopState
virtual void setLoopState(bool bState)
Definition: sensordatatreeitem.cpp:262
FIFFLIB::FiffCoordTrans
Coordinate transformation description.
Definition: fiff_coord_trans.h:74
DISP3DLIB::RtSensorDataController
This controller organizes data streaming and interpolation matrix calculations. It only uses Queued s...
Definition: rtsensordatacontroller.h:86
DISP3DLIB::GpuInterpolationItem
This item is used for signal interpolation with GPU support.
Definition: gpuinterpolationitem.h:98
FIFFLIB::FiffChInfo::kind
fiff_int_t kind
Definition: fiff_ch_info.h:121
DISP3DLIB::SensorDataTreeItem::onLoopStateChanged
virtual void onLoopStateChanged(const Qt::CheckState &checkState)
Definition: sensordatatreeitem.cpp:655
DISP3DLIB::SensorDataTreeItem::m_pInterpolationItemGPU
QPointer< GpuInterpolationItem > m_pInterpolationItemGPU
Definition: sensordatatreeitem.h:368
DISP3DLIB::SensorDataTreeItem::setStreamingState
virtual void setStreamingState(bool bState)
Definition: sensordatatreeitem.cpp:278
MNELIB::MNEBemSurface
BEM surface provides geometry information.
Definition: mne_bem_surface.h:79
DISP3DLIB::AbstractTreeItem::checkStateChanged
void checkStateChanged(const Qt::CheckState &checkState)
DISP3DLIB::SensorDataTreeItem::onStreamingStateChanged
virtual void onStreamingStateChanged(const Qt::CheckState &checkState)
Definition: sensordatatreeitem.cpp:597
DISP3DLIB::Abstract3DTreeItem::createVertColor
static Eigen::MatrixX4f createVertColor(int numVert, const QColor &color=QColor(0, 49, 69))
Definition: abstract3Dtreeitem.cpp:246
DISP3DLIB::SensorDataTreeItem::initItem
virtual void initItem() override
Definition: sensordatatreeitem.cpp:470
DISP3DLIB::SensorDataTreeItem::setColormapType
virtual void setColormapType(const QString &sColormap)
Definition: sensordatatreeitem.cpp:326
DISP3DLIB::SensorDataTreeItem::m_iUsedSensors
QVector< int > m_iUsedSensors
Definition: sensordatatreeitem.h:364
DISP3DLIB::SensorDataTreeItem::m_pInterpolationItemCPU
QPointer< AbstractMeshTreeItem > m_pInterpolationItemCPU
Definition: sensordatatreeitem.h:369
DISP3DLIB::SensorDataTreeItem::setTimeInterval
virtual void setTimeInterval(int iMSec)
Definition: sensordatatreeitem.cpp:294
DISP3DLIB::SensorDataTreeItem::onDataThresholdChanged
virtual void onDataThresholdChanged(const QVariant &vecThresholds)
Definition: sensordatatreeitem.cpp:638
FIFFLIB::FiffChInfo::chpos
FiffChPos chpos
Definition: fiff_ch_info.h:124