MNE-CPP
beta 1.0
Main Page
Related Pages
Modules
Classes
Files
File List
File Members
MNE
fs
label.h
Go to the documentation of this file.
1
//=============================================================================================================
36
#ifndef LABEL_H
37
#define LABEL_H
38
39
//*************************************************************************************************************
40
//=============================================================================================================
41
// INCLUDES
42
//=============================================================================================================
43
44
#include "
fs_global.h
"
45
46
47
//*************************************************************************************************************
48
//=============================================================================================================
49
// QT INCLUDES
50
//=============================================================================================================
51
52
#include <QSharedPointer>
53
#include <QMap>
54
55
56
//*************************************************************************************************************
57
//=============================================================================================================
58
// Eigen INCLUDES
59
//=============================================================================================================
60
61
#include <Eigen/Core>
62
63
64
//*************************************************************************************************************
65
//=============================================================================================================
66
// DEFINE NAMESPACE FSLIB
67
//=============================================================================================================
68
69
namespace
FSLIB
70
{
71
72
const
static
Eigen::MatrixX3i defaultTris(0,3);
73
74
75
//*************************************************************************************************************
76
//=============================================================================================================
77
// USED NAMESPACES
78
//=============================================================================================================
79
80
using namespace
Eigen
;
81
82
83
//*************************************************************************************************************
84
//=============================================================================================================
85
// FORWARD DECLARATIONS
86
//=============================================================================================================
87
88
class
Surface;
89
90
91
//=============================================================================================================
97
class
FSSHARED_EXPORT
Label
98
{
99
public
:
100
typedef
QSharedPointer<Label>
SPtr
;
101
typedef
QSharedPointer<const Label>
ConstSPtr
;
103
//=========================================================================================================
107
Label
();
108
109
//=========================================================================================================
120
Label
(
const
VectorXi &p_vertices,
const
MatrixX3f &p_pos,
const
VectorXd &p_values, qint32 p_hemi,
const
QString &p_name, qint32 p_id = -1);
121
122
//=========================================================================================================
126
~
Label
();
127
128
//=========================================================================================================
132
void
clear();
133
134
//=========================================================================================================
140
inline
bool
isEmpty()
const
;
141
142
//=========================================================================================================
150
MatrixX3i selectTris(
const
Surface
& p_Surface);
151
152
//=========================================================================================================
160
MatrixX3i selectTris(
const
MatrixX3i &p_matTris);
161
162
//=========================================================================================================
175
static
bool
read(
const
QString& p_sFileName,
Label
&p_Label);
176
177
public
:
178
QString
comment
;
179
VectorXi
vertices
;
180
MatrixX3f
pos
;
181
VectorXd
values
;
182
qint32
hemi
;
183
// qint32 hemi; /**< Hemisphere (lh = 0; rh = 1; both = 2) */ Don't mix both hemis - KISS principle
184
QString
name
;
185
qint32
label_id
;
186
// MatrixX3i tris; /**< Tris for plotting (optional) */
187
188
// QMap<qint32, VectorXi> vertices; /**< Vertex indices (0 based) */
189
// QMap<qint32, MatrixX3d> pos; /**< Locations in meters */
190
// QMap<qint32, VectorXd> values; /**< Values at the vertices */
191
};
192
193
//*************************************************************************************************************
194
//=============================================================================================================
195
// INLINE DEFINITIONS
196
//=============================================================================================================
197
198
inline
bool
Label::isEmpty
()
const
199
{
200
return
this->hemi == -1;
201
}
202
203
}
// NAMESPACE
204
205
#endif // LABEL_H
FSLIB::Label::ConstSPtr
QSharedPointer< const Label > ConstSPtr
Definition:
label.h:101
FSLIB::Label::pos
MatrixX3f pos
Definition:
label.h:180
FSLIB::Label::SPtr
QSharedPointer< Label > SPtr
Definition:
label.h:100
fs_global.h
Fs library export/import macros.
FSLIB::Label::comment
QString comment
Definition:
label.h:178
Eigen
FSLIB::Label::hemi
qint32 hemi
Definition:
label.h:182
FSLIB::Label::name
QString name
Definition:
label.h:184
FSLIB::Surface
FreeSurfer surface mesh.
Definition:
surface.h:92
FSLIB::Label::vertices
VectorXi vertices
Definition:
label.h:179
FSLIB::Label::label_id
qint32 label_id
Definition:
label.h:185
FSSHARED_EXPORT
#define FSSHARED_EXPORT
Definition:
fs_global.h:58
FSLIB::Label::isEmpty
bool isEmpty() const
Definition:
label.h:198
FSLIB::Label
Freesurfer/MNE label.
Definition:
label.h:97
FSLIB
Definition:
inverseview.h:81
FSLIB::Label::values
VectorXd values
Definition:
label.h:181
Generated on Fri Mar 27 2015 22:54:31 for MNE-CPP by
1.8.9.1