MNE-CPP 0.1.9
A Framework for Electrophysiology
Loading...
Searching...
No Matches
fiff_info.h
Go to the documentation of this file.
1//=============================================================================================================
38#ifndef FIFF_INFO_H
39#define FIFF_INFO_H
40
41//=============================================================================================================
42// INCLUDES
43//=============================================================================================================
44
45#include "fiff_global.h"
46
47#include "fiff_info_base.h"
48
49#include "fiff_types.h"
50#include "fiff_id.h"
51#include "fiff_ch_info.h"
52#include "fiff_dig_point.h"
53#include "fiff_ctf_comp.h"
54#include "fiff_coord_trans.h"
55#include "fiff_proj.h"
56
57//=============================================================================================================
58// QT INCLUDES
59//=============================================================================================================
60
61#include <QList>
62#include <QStringList>
63#include <QSharedPointer>
64
65//=============================================================================================================
66// DEFINE NAMESPACE FIFFLIB
67//=============================================================================================================
68
69namespace FIFFLIB
70{
71
72//=============================================================================================================
73// FIFFLIB FORWARD DECLARATIONS
74//=============================================================================================================
75
76class FiffStream;
77
78//=============================================================================================================
85{
86public:
87 typedef QSharedPointer<FiffInfo> SPtr;
88 typedef QSharedPointer<const FiffInfo> ConstSPtr;
90 //=========================================================================================================
94 FiffInfo();
95
96 //=========================================================================================================
102 FiffInfo(const FiffInfo& p_FiffInfo);
103
104 //=========================================================================================================
108 ~FiffInfo();
109
110 //=========================================================================================================
114 void clear();
115
116 //=========================================================================================================
131 bool make_compensator(fiff_int_t from, fiff_int_t to, FiffCtfComp& ctf_comp, bool exclude_comp_chs = false) const;
132
133 //=========================================================================================================
143 qint32 get_current_comp();
144
145 //=========================================================================================================
157 inline qint32 make_projector(Eigen::MatrixXd& proj) const;
158
159 //=========================================================================================================
172 inline qint32 make_projector(Eigen::MatrixXd& proj, const QStringList& p_chNames) const;
173
174 //=========================================================================================================
186 FiffInfo pick_info(const Eigen::RowVectorXi &sel = defaultVectorXi) const;
187
188 //=========================================================================================================
194 inline void set_current_comp(fiff_int_t value);
195
196 //=========================================================================================================
212 static QList<FiffChInfo> set_current_comp(QList<FiffChInfo>& listFiffChInfo, fiff_int_t value);
213
214// ToDo
215// //=========================================================================================================
216// /**
217// * Writes the fiff information to an I/O Device, e.g. fiff file
218// *
219// * @param[in] p_IODevice IO device to write the fiff info to.
220// */
221// void write(QIODevice &p_IODevice);
222
223 //=========================================================================================================
229 void writeToStream(FiffStream* p_pStream) const;
230
231 //=========================================================================================================
235 void print() const;
236
237private:
238 //=========================================================================================================
249 bool make_compensator(fiff_int_t kind, Eigen::MatrixXd& this_comp) const;
250
251public: //Public because it's a mne struct
253 fiff_int_t meas_date[2];
254 float sfreq;
255 float linefreq;
256 float highpass;
257 float lowpass;
259 QString proj_name;
261 QString experimenter;
262 QString description;
263 QString utc_offset;
264 fiff_int_t gantry_angle;
266 QList<FiffDigPoint> dig;
268 QList<FiffProj> projs;
269 QList<FiffCtfComp> comps;
270 QString acq_pars;
271 QString acq_stim;
272};
273
274//=============================================================================================================
275// INLINE DEFINITIONS
276//=============================================================================================================
277
278inline qint32 FiffInfo::make_projector(Eigen::MatrixXd& proj) const
279{
280 return FiffProj::make_projector(this->projs,this->ch_names, proj, this->bads);
281}
282
283//=============================================================================================================
284
285inline qint32 FiffInfo::make_projector(Eigen::MatrixXd& proj, const QStringList& p_chNames) const
286{
287 return FiffProj::make_projector(this->projs, p_chNames, proj, this->bads);
288}
289
290//=============================================================================================================
291
292inline void FiffInfo::set_current_comp(fiff_int_t value)
293{
294 this->chs = set_current_comp(this->chs, value);
295}
296} // NAMESPACE
297
298#endif // FIFF_INFO_H
Fiff library export/import macros.
#define FIFFSHARED_EXPORT
Definition fiff_global.h:56
FiffInfoBase class declaration.
FiffCtfComp class declaration.
FiffChInfo class declaration.
FiffId class declaration.
FiffProj class declaration.
Definitions for describing the objects in a FIFF file.
FiffCoordTrans class declaration.
FiffDigPoint class declaration.
Coordinate transformation description.
CTF software compensation data.
Universially unique identifier.
Definition fiff_id.h:68
FIFF measurement file information.
Definition fiff_info.h:85
void set_current_comp(fiff_int_t value)
Definition fiff_info.h:292
QString description
Definition fiff_info.h:262
qint32 make_projector(Eigen::MatrixXd &proj) const
Definition fiff_info.h:278
FiffCoordTrans dev_ctf_t
Definition fiff_info.h:265
QSharedPointer< const FiffInfo > ConstSPtr
Definition fiff_info.h:88
fiff_int_t gantry_angle
Definition fiff_info.h:264
FiffCoordTrans dig_trans
Definition fiff_info.h:267
QList< FiffCtfComp > comps
Definition fiff_info.h:269
QSharedPointer< FiffInfo > SPtr
Definition fiff_info.h:87
QString xplotter_layout
Definition fiff_info.h:260
QList< FiffDigPoint > dig
Definition fiff_info.h:266
QString experimenter
Definition fiff_info.h:261
QList< FiffProj > projs
Definition fiff_info.h:268
light measurement info
QList< FiffChInfo > chs
static fiff_int_t make_projector(const QList< FiffProj > &projs, const QStringList &ch_names, Eigen::MatrixXd &proj, const QStringList &bads=defaultQStringList, Eigen::MatrixXd &U=defaultMatrixXd)
FIFF File I/O routines.