Renderable sEEG / ECoG electrodes: contact spheres plus lead bodies.
More...
#include <electrodeobject.h>
Renderable sEEG / ECoG electrodes: contact spheres plus lead bodies.
Definition at line 59 of file electrodeobject.h.
◆ ElectrodeObject()
| ElectrodeObject::ElectrodeObject |
( |
| ) |
|
◆ ~ElectrodeObject()
| ElectrodeObject::~ElectrodeObject |
( |
| ) |
|
|
default |
◆ bodyRenderKey()
| const RenderKey & DISP3DLIB::ElectrodeObject::bodyRenderKey |
( |
| ) |
const |
|
inline |
- Returns
- Identity of the body mesh in the renderer's GPU cache.
Definition at line 202 of file electrodeobject.h.
◆ bodyStreams()
- Returns
- Instanced streams of the lead bodies (unit cylinders: shafts and ties).
Definition at line 455 of file electrodeobject.cpp.
◆ boundingBoxMax()
| QVector3D ElectrodeObject::boundingBoxMax |
( |
| ) |
const |
- Returns
- Axis-aligned bounding box maximum corner (with contact-radius padding).
Definition at line 473 of file electrodeobject.cpp.
◆ boundingBoxMin()
| QVector3D ElectrodeObject::boundingBoxMin |
( |
| ) |
const |
- Returns
- Axis-aligned bounding box minimum corner (with contact-radius padding).
Definition at line 466 of file electrodeobject.cpp.
◆ clearContactValues()
| void ElectrodeObject::clearContactValues |
( |
| ) |
|
◆ clearSelection()
| void ElectrodeObject::clearSelection |
( |
| ) |
|
◆ contactAt()
- Parameters
-
- Returns
- The contact, or nullptr when out of range.
Definition at line 422 of file electrodeobject.cpp.
◆ contactLabel()
| QString ElectrodeObject::contactLabel |
( |
int | index | ) |
const |
- Parameters
-
- Returns
- Hover text, e.g. "LA3 (depth lead LA)", or an empty string when out of range.
Definition at line 429 of file electrodeobject.cpp.
◆ contactRenderKey()
| const RenderKey & DISP3DLIB::ElectrodeObject::contactRenderKey |
( |
| ) |
const |
|
inline |
- Returns
- Identity of the contact mesh in the renderer's GPU cache.
Definition at line 196 of file electrodeobject.h.
◆ contactStreams()
- Returns
- Instanced streams of the contact spheres (one instance per contact).
Definition at line 444 of file electrodeobject.cpp.
◆ hoveredContact()
| int DISP3DLIB::ElectrodeObject::hoveredContact |
( |
| ) |
const |
|
inline |
◆ implantation()
◆ intersect()
| int ElectrodeObject::intersect |
( |
const QVector3D & | rayOrigin, |
|
|
const QVector3D & | rayDir, |
|
|
float & | dist ) const |
Intersect a ray with the contact spheres.
- Parameters
-
| [in] | rayOrigin | Ray origin. |
| [in] | rayDir | Normalised ray direction. |
| [out] | dist | Distance to the nearest hit. |
- Returns
- Index of the nearest contact hit, or -1.
Definition at line 396 of file electrodeobject.cpp.
◆ isVisible()
| bool DISP3DLIB::ElectrodeObject::isVisible |
( |
| ) |
const |
|
inline |
◆ leadColor()
| QColor ElectrodeObject::leadColor |
( |
int | index | ) |
|
|
static |
- Parameters
-
- Returns
- Lead colour: golden-angle hues, so neighbouring leads differ clearly.
Definition at line 291 of file electrodeobject.cpp.
◆ selectContact()
| void ElectrodeObject::selectContact |
( |
const QString & | name | ) |
|
Select a contact by name. Clears the previous selection.
- Parameters
-
| [in] | name | Contact name to select. |
Definition at line 259 of file electrodeobject.cpp.
◆ selectedContact()
| QString ElectrodeObject::selectedContact |
( |
| ) |
const |
- Returns
- Name of the currently selected contact, or empty string if none.
Definition at line 284 of file electrodeobject.cpp.
◆ setContactValues()
| void ElectrodeObject::setContactValues |
( |
const QMap< QString, float > & | values, |
|
|
const QString & | colormap = QStringLiteral("Hot") ) |
Colour contacts by value through a colormap spanning [min(0, smallest), largest]. Contacts without a value keep the colour of their lead.
- Parameters
-
Definition at line 176 of file electrodeobject.cpp.
◆ setHoveredContact()
| void ElectrodeObject::setHoveredContact |
( |
int | index | ) |
|
Highlight one contact while the pointer is over it, without changing the selection.
- Parameters
-
| [in] | index | Contact index (as returned by intersect), or -1 for none. |
Definition at line 274 of file electrodeobject.cpp.
◆ setImplantation()
Draw an implantation. Clears the selection, hover and contact colours.
- Parameters
-
| [in] | implantation | Contacts and leads, positions in the frame of the surfaces. |
Definition at line 148 of file electrodeobject.cpp.
◆ setVisible()
| void DISP3DLIB::ElectrodeObject::setVisible |
( |
bool | visible | ) |
|
|
inline |
◆ surfaceColors()
| QVector< uint32_t > ElectrodeObject::surfaceColors |
( |
const Eigen::MatrixX3f & | vertices, |
|
|
double | distance = 0.01 ) const |
Paint the contact values onto a surface, as MNE-Python's stc_near_sensors: each vertex takes the distance-weighted mean of the contacts within reach and fades out with the summed weight. ECoG contacts are first moved onto the surface; depth contacts are not.
- Parameters
-
| [in] | vertices | Surface vertex positions in the frame of the implantation, metres. |
| [in] | distance | Reach of each contact in metres. |
- Returns
- ABGR colour per vertex, transparent away from the contacts; empty without values.
Definition at line 219 of file electrodeobject.cpp.
◆ totalContactCount()
| int ElectrodeObject::totalContactCount |
( |
| ) |
const |
◆ kDepthContactRadius
| float DISP3DLIB::ElectrodeObject::kDepthContactRadius = 0.0011f |
|
staticconstexpr |
◆ kMaxTieLength
| float DISP3DLIB::ElectrodeObject::kMaxTieLength = 0.015f |
|
staticconstexpr |
◆ kShaftOvershoot
| float DISP3DLIB::ElectrodeObject::kShaftOvershoot = 0.004f |
|
staticconstexpr |
◆ kShaftRadius
| float DISP3DLIB::ElectrodeObject::kShaftRadius = 0.00045f |
|
staticconstexpr |
◆ kSubduralContactRadius
| float DISP3DLIB::ElectrodeObject::kSubduralContactRadius = 0.0019f |
|
staticconstexpr |
◆ kTieRadius
| float DISP3DLIB::ElectrodeObject::kTieRadius = 0.00035f |
|
staticconstexpr |
Ties between neighbouring strip / grid contacts.
Definition at line 68 of file electrodeobject.h.
The documentation for this class was generated from the following files: