v2.0.0
Loading...
Searching...
No Matches
FIFFLIB::FiffChInfo Class Reference

Per-channel FIFF descriptor: identifiers, kind, calibration, coil type, channel-frame coil position and SI unit. More...

#include <fiff_ch_info.h>

Public Types

using SPtr = QSharedPointer<FiffChInfo>
using ConstSPtr = QSharedPointer<const FiffChInfo>
using UPtr = std::unique_ptr<FiffChInfo>
using ConstUPtr = std::unique_ptr<const FiffChInfo>

Public Member Functions

 FiffChInfo ()
 FiffChInfo (const FiffChInfo &p_FiffChInfo)
FiffChInfo & operator= (const FiffChInfo &other)=default
 ~FiffChInfo ()
bool isValidEeg () const

Static Public Member Functions

static qint32 storageSize ()
static bool checkEegLocations (const QList< FiffChInfo > &chs, int nch)

Public Attributes

fiff_int_t scanNo
fiff_int_t logNo
fiff_int_t kind
fiff_float_t range
fiff_float_t cal
FiffChPos chpos
fiff_int_t unit
fiff_int_t unit_mul
QString ch_name
Eigen::Matrix< float, 4, 4, Eigen::DontAlign > coil_trans
Eigen::Matrix< float, 3, 2, Eigen::DontAlign > eeg_loc
fiff_int_t coord_frame

Friends

bool operator== (const FiffChInfo &a, const FiffChInfo &b)

Detailed Description

Per-channel FIFF descriptor: identifiers, kind, calibration, coil type, channel-frame coil position and SI unit.

Holds the exact field set of the on-disk fiffChInfoRec: scanno, logno, kind, range, cal, coil_type, the embedded FiffChPos coil location, unit and unit_mul. The ch_name string lives next to the record because the FIFF stream stores it as a separate FIFF_CH_NAME tag in modern files.

Definition at line 77 of file fiff_ch_info.h.

Member Typedef Documentation

◆ ConstSPtr

using FIFFLIB::FiffChInfo::ConstSPtr = QSharedPointer<const FiffChInfo>

Const shared pointer type for FiffChInfo.

Definition at line 81 of file fiff_ch_info.h.

◆ ConstUPtr

using FIFFLIB::FiffChInfo::ConstUPtr = std::unique_ptr<const FiffChInfo>

Const unique pointer type for FiffChInfo.

Definition at line 83 of file fiff_ch_info.h.

◆ SPtr

using FIFFLIB::FiffChInfo::SPtr = QSharedPointer<FiffChInfo>

Shared pointer type for FiffChInfo.

Definition at line 80 of file fiff_ch_info.h.

◆ UPtr

using FIFFLIB::FiffChInfo::UPtr = std::unique_ptr<FiffChInfo>

Unique pointer type for FiffChInfo.

Definition at line 82 of file fiff_ch_info.h.

Constructor & Destructor Documentation

◆ FiffChInfo() [1/2]

FiffChInfo::FiffChInfo ( )

Constructs the channel info descriptor.

Definition at line 38 of file fiff_ch_info.cpp.

◆ FiffChInfo() [2/2]

FiffChInfo::FiffChInfo ( const FiffChInfo & p_FiffChInfo)

Copy constructor.

Parameters
[in]p_FiffChInfoChannel Info descriptor which should be copied.

Definition at line 57 of file fiff_ch_info.cpp.

◆ ~FiffChInfo()

FiffChInfo::~FiffChInfo ( )

Destroys the channel info descriptor.

Definition at line 75 of file fiff_ch_info.cpp.

Member Function Documentation

◆ checkEegLocations()

bool FiffChInfo::checkEegLocations ( const QList< FiffChInfo > & chs,
int nch )
static

Check that all EEG channels in the list have reasonable (non-origin) locations. Formerly mne_check_chinfo (MNE C).

Parameters
[in]chsThe list of channel info structures to check.
[in]nchThe number of channels to check.
Returns
true if all EEG channels have valid locations, false otherwise.

Definition at line 81 of file fiff_ch_info.cpp.

◆ isValidEeg()

bool FiffChInfo::isValidEeg ( ) const

Check whether this channel has a valid EEG electrode position.

A channel is a valid EEG channel if its kind is FIFFV_EEG_CH, its electrode position is not at the origin, and its coil type is not FIFFV_COIL_NONE.

Returns
true if this is a valid EEG channel with proper electrode location.

Definition at line 97 of file fiff_ch_info.cpp.

◆ operator=()

FiffChInfo & FIFFLIB::FiffChInfo::operator= ( const FiffChInfo & other)
default

Copy assignment. Every member has value semantics, so the compiler-generated member-wise assignment is correct. It is declared explicitly because declaring a copy constructor and/or a destructor deprecates the implicitly generated one.

Parameters
[in]otherObject to assign from.
Returns
reference to this object.

◆ storageSize()

qint32 FIFFLIB::FiffChInfo::storageSize ( )
inlinestatic

Size of the old struct (fiffChInfoRec) 20*int + 16 = 20*4 + 16 = 96

Returns
the size of the old struct fiffChInfoRec.

Definition at line 180 of file fiff_ch_info.h.

◆ operator==

bool operator== ( const FiffChInfo & a,
const FiffChInfo & b )
friend

Overloaded == operator to compare an object to this instance.

Parameters
[in]aThe object which should be compared to.
[in]bRight-hand channel info.
Returns
true if equal, false otherwise.

Definition at line 189 of file fiff_ch_info.h.

Member Data Documentation

◆ cal

fiff_float_t FIFFLIB::FiffChInfo::cal

Calibration from volts to units used.

Definition at line 164 of file fiff_ch_info.h.

◆ ch_name

QString FIFFLIB::FiffChInfo::ch_name

Descriptive name for the channel.

Definition at line 168 of file fiff_ch_info.h.

◆ chpos

FiffChPos FIFFLIB::FiffChInfo::chpos

Channel location.

Definition at line 165 of file fiff_ch_info.h.

◆ coil_trans

Eigen::Matrix<float, 4, 4, Eigen::DontAlign> FIFFLIB::FiffChInfo::coil_trans

Coil coordinate system transformation.

Definition at line 171 of file fiff_ch_info.h.

◆ coord_frame

fiff_int_t FIFFLIB::FiffChInfo::coord_frame

Coordinate Frame.

Definition at line 173 of file fiff_ch_info.h.

◆ eeg_loc

Eigen::Matrix<float, 3, 2, Eigen::DontAlign> FIFFLIB::FiffChInfo::eeg_loc

Channel location.

Definition at line 172 of file fiff_ch_info.h.

◆ kind

fiff_int_t FIFFLIB::FiffChInfo::kind

Kind of channel.

Definition at line 162 of file fiff_ch_info.h.

◆ logNo

fiff_int_t FIFFLIB::FiffChInfo::logNo

Logical channel #.

Definition at line 161 of file fiff_ch_info.h.

◆ range

fiff_float_t FIFFLIB::FiffChInfo::range

Voltmeter range (-1 = auto ranging).

Definition at line 163 of file fiff_ch_info.h.

◆ scanNo

fiff_int_t FIFFLIB::FiffChInfo::scanNo

Scanning order number.

Definition at line 160 of file fiff_ch_info.h.

◆ unit

fiff_int_t FIFFLIB::FiffChInfo::unit

Unit of measurement.

Definition at line 166 of file fiff_ch_info.h.

◆ unit_mul

fiff_int_t FIFFLIB::FiffChInfo::unit_mul

Unit multiplier exponent.

Definition at line 167 of file fiff_ch_info.h.


The documentation for this class was generated from the following files: