54 #include <OpenMEEG_Export.h> 97 Sensors(
const char* filename): m_geo(NULL) { this->load(filename,
't'); }
98 Sensors(
const char* filename,
const Geometry& g): m_geo(&g) { this->load(filename,
't'); };
100 void load(
const char* filename,
char filetype =
't' );
101 void load(std::istream &in);
102 void save(
const char* filename);
116 bool hasRadii()
const {
return m_radii.nlin() > 0 ;}
118 bool hasNames()
const {
return m_names.size() == m_nb ;}
119 Vector getPosition(
size_t idx)
const;
120 Vector getOrientation(
size_t idx)
const;
121 std::string
getName(
size_t idx)
const{ om_assert(idx < m_names.size());
return m_names[idx]; }
122 void setPosition(
size_t idx,
Vector& pos);
123 void setOrientation(
size_t idx,
Vector& orient);
125 bool hasSensor(std::string name);
126 size_t getSensorIdx(std::string name);
134 bool isEmpty() {
if(m_nb == 0)
return true;
else return false; }
147 void findInjectionTriangles();
151 return m_positions.getlin(idx);
155 return m_orientations.getlin(idx);
159 return m_positions.setlin(idx,pos);
163 return m_orientations.setlin(idx,orient);
void setOrientation(size_t idx, Vector &orient)
size_t getNumberOfSensors() const
Matrix getOrientations() const
Geometry contains the electrophysiological model Here are stored the vertices, meshes and domains...
Triangles getInjectionTriangles(size_t idx) const
std::vector< std::string > Strings
Matrix getPositions() const
std::vector< Triangle > Triangles
void setPosition(size_t idx, Vector &pos)
std::vector< size_t > m_pointSensorIdx
bool hasOrientations() const
Vector getWeights() const
Sensors(const char *filename)
Vector getPosition(size_t idx) const
Matrix & getOrientations()
Sensors(const char *filename, const Geometry &g)
std::string getName(size_t idx) const
size_t getNumberOfPositions() const
Sensors(const Geometry &g)
Vector getOrientation(size_t idx) const
std::vector< Triangles > m_triangles