v2.0.0
Loading...
Searching...
No Matches
DISPLIB::AverageLayoutView Class Reference

Sensor-layout viewer drawing per-channel evoked traces at their physical 2-D positions. More...

#include <averagelayoutview.h>

Public Types

typedef QSharedPointer< AverageLayoutView > SPtr
typedef QSharedPointer< const AverageLayoutView > ConstSPtr
Public Types inherited from DISPLIB::AbstractView
enum  StyleMode { Default , Dark }
enum  GuiMode { Clinical , Research }
enum  ProcessingMode { RealTime , Offline }
typedef QSharedPointer< AbstractView > SPtr
typedef QSharedPointer< const AbstractView > ConstSPtr

Public Member Functions

 AverageLayoutView (const QString &sSettingsPath="", QWidget *parent=0, Qt::WindowFlags f=Qt::Widget)
 ~AverageLayoutView ()
void updateViewport ()
void setChannelInfoModel (QSharedPointer< ChannelInfoModel > &pChannelInfoModel)
void setEvokedSetModel (QSharedPointer< EvokedSetModel > pEvokedSetModel)
QSharedPointer< EvokedSetModel > getEvokedSetModel ()
void setBackgroundColor (const QColor &backgroundColor)
QColor getBackgroundColor ()
void takeScreenshot (const QString &fileName)
void setScaleMap (const QMap< qint32, float > &scaleMap)
QSharedPointer< QMap< QString, QColor > > getAverageColor () const
QSharedPointer< QMap< QString, bool > > getAverageActivation () const
void setAverageColor (const QSharedPointer< QMap< QString, QColor > > qMapAverageColor)
void setSingleAverageColor (const QColor &avgColor)
void setAverageActivation (const QSharedPointer< QMap< QString, bool > > qMapAverageActivation)
void setFiffInfo (const QSharedPointer< FIFFLIB::FiffInfo > pFiffInfo)
void channelSelectionManagerChanged (const QList< QGraphicsItem * > &selectedChannelItems)
void channelSelectionChanged (const QVariant &selectionData)
void updateData ()
void saveSettings ()
void loadSettings ()
void clearView ()
Public Member Functions inherited from DISPLIB::AbstractView
 AbstractView (QWidget *parent=0, Qt::WindowFlags f=Qt::Widget)
virtual void setGuiMode (GuiMode mode)
virtual void setProcessingMode (ProcessingMode mode)

Protected Member Functions

void updateGuiMode (GuiMode mode)
void updateProcessingMode (ProcessingMode mode)

Protected Attributes

QSharedPointer< AverageScene > m_pAverageScene
QSharedPointer< DISPLIB::EvokedSetModel > m_pEvokedSetModel
QSharedPointer< DISPLIB::ChannelInfoModel > m_pChannelInfoModel
QSharedPointer< FIFFLIB::FiffInfo > m_pFiffInfo
QPointer< QGraphicsView > m_pAverageLayoutView
QSharedPointer< QMap< QString, QColor > > m_qMapAverageColor
QSharedPointer< QMap< QString, bool > > m_qMapAverageActivation
QMap< qint32, float > m_scaleMap
Protected Attributes inherited from DISPLIB::AbstractView
bool m_bResearchModeIsActive
bool m_bOfflineModeIsActive
QString m_sSettingsPath

Additional Inherited Members

Signals inherited from DISPLIB::AbstractView
void guiStyleChanged (DISPLIB::AbstractView::StyleMode style)

Detailed Description

Sensor-layout viewer drawing per-channel evoked traces at their physical 2-D positions.

Wraps a QGraphicsView around an AverageScene fed by an EvokedSetModel and a ChannelInfoModel; selection groups are pushed in as SelectionItem to show only a subset of channels.

Definition at line 78 of file averagelayoutview.h.

Inheritance diagram for DISPLIB::AverageLayoutView:
Inheritance graph

Member Typedef Documentation

◆ ConstSPtr

Const shared pointer type for AverageLayoutView.

Definition at line 84 of file averagelayoutview.h.

◆ SPtr

Shared pointer type for AverageLayoutView.

Definition at line 83 of file averagelayoutview.h.

Constructor & Destructor Documentation

◆ AverageLayoutView()

AverageLayoutView::AverageLayoutView ( const QString & sSettingsPath = "",
QWidget * parent = 0,
Qt::WindowFlags f = Qt::Widget )

Constructs a AverageLayoutView which is a child of parent.

Parameters
[in]sSettingsPathSettings path under which the widget persists its state (empty = no persistence).
[in]parentparent of widget.
[in]fQt window flags passed to the QWidget constructor.

Definition at line 55 of file averagelayoutview.cpp.

◆ ~AverageLayoutView()

AverageLayoutView::~AverageLayoutView ( )

Destroys the AverageLayoutView.

Definition at line 97 of file averagelayoutview.cpp.

Member Function Documentation

◆ channelSelectionChanged()

void AverageLayoutView::channelSelectionChanged ( const QVariant & selectionData)

Sets the currently viewable channels using the corrent name and location parameters

Parameters
[in]selectionDataQVariant containing a SelectionItem object with selected channel information.

Definition at line 279 of file averagelayoutview.cpp.

◆ channelSelectionManagerChanged()

void AverageLayoutView::channelSelectionManagerChanged ( const QList< QGraphicsItem * > & selectedChannelItems)

call this whenever the external channel selection manager changes

  • Parameters
    [in]selectedChannelItemslist of selected graphic items

Definition at line 263 of file averagelayoutview.cpp.

◆ clearView()

void AverageLayoutView::clearView ( )
virtual

Clears the view

Implements DISPLIB::AbstractView.

Definition at line 438 of file averagelayoutview.cpp.

◆ getAverageActivation()

QSharedPointer< QMap< QString, bool > > AverageLayoutView::getAverageActivation ( ) const

Get the current average activations

Returns
Pointer to the current average activations.

Definition at line 218 of file averagelayoutview.cpp.

◆ getAverageColor()

QSharedPointer< QMap< QString, QColor > > AverageLayoutView::getAverageColor ( ) const

Get the current average colors

Returns
Pointer to the current average colors.

Definition at line 211 of file averagelayoutview.cpp.

◆ getBackgroundColor()

QColor AverageLayoutView::getBackgroundColor ( )

Returns the background color of the scene.

Returns
The current background color.

Definition at line 156 of file averagelayoutview.cpp.

◆ getEvokedSetModel()

QSharedPointer< EvokedSetModel > AverageLayoutView::getEvokedSetModel ( )

Returns the currently set EvokedSetModel

Returns
the currently set EvokedSetModel.

Definition at line 431 of file averagelayoutview.cpp.

◆ loadSettings()

void AverageLayoutView::loadSettings ( )
virtual

Loads and inits all important settings of this view via QSettings.

Implements DISPLIB::AbstractView.

Definition at line 389 of file averagelayoutview.cpp.

◆ saveSettings()

void AverageLayoutView::saveSettings ( )
virtual

Saves all important settings of this view via QSettings.

Implements DISPLIB::AbstractView.

Definition at line 378 of file averagelayoutview.cpp.

◆ setAverageActivation()

void AverageLayoutView::setAverageActivation ( const QSharedPointer< QMap< QString, bool > > qMapAverageActivation)

Set the average activations

Parameters
[in]qMapAverageActivationPointer to the new average activations.

Definition at line 250 of file averagelayoutview.cpp.

◆ setAverageColor()

void AverageLayoutView::setAverageColor ( const QSharedPointer< QMap< QString, QColor > > qMapAverageColor)

Set the average colors

Parameters
[in]qMapAverageColorPointer to the new average colors.

Definition at line 225 of file averagelayoutview.cpp.

◆ setBackgroundColor()

void AverageLayoutView::setBackgroundColor ( const QColor & backgroundColor)

Sets the background color of the scene.

Parameters
[in]backgroundColorThe new background color.

Definition at line 142 of file averagelayoutview.cpp.

◆ setChannelInfoModel()

void AverageLayoutView::setChannelInfoModel ( QSharedPointer< ChannelInfoModel > & pChannelInfoModel)

Sets the channel info model.

Parameters
[in]pChannelInfoModelThe new channel info model.

Definition at line 123 of file averagelayoutview.cpp.

◆ setEvokedSetModel()

void AverageLayoutView::setEvokedSetModel ( QSharedPointer< EvokedSetModel > pEvokedSetModel)

Sets the evoked set model.

Parameters
[in]pEvokedSetModelThe new evoked set model.

Definition at line 130 of file averagelayoutview.cpp.

◆ setFiffInfo()

void AverageLayoutView::setFiffInfo ( const QSharedPointer< FIFFLIB::FiffInfo > pFiffInfo)

Stores FiffInfo to local variable to be used for getting channel info

Parameters
[in]pFiffInfoshared pointer to Fiff Info of currently loaded data.

Definition at line 424 of file averagelayoutview.cpp.

◆ setScaleMap()

void AverageLayoutView::setScaleMap ( const QMap< qint32, float > & scaleMap)

Sets the scale map to scaleMap.

Parameters
[in]scaleMapmap with all channel types and their current scaling value.

Definition at line 195 of file averagelayoutview.cpp.

◆ setSingleAverageColor()

void AverageLayoutView::setSingleAverageColor ( const QColor & avgColor)

Sets the color used to draw the average to avgColor

Parameters
[in]avgColorColor of averaged signal.

Definition at line 238 of file averagelayoutview.cpp.

◆ takeScreenshot()

void AverageLayoutView::takeScreenshot ( const QString & fileName)

Renders a screenshot of the scene and saves it to the passed path. SVG and PNG supported.

Parameters
[in]fileNameThe file name and path where to store the screenshot.

Definition at line 168 of file averagelayoutview.cpp.

◆ updateData()

void AverageLayoutView::updateData ( )

call this function whenever the items' data needs to be updated

Definition at line 298 of file averagelayoutview.cpp.

◆ updateGuiMode()

void AverageLayoutView::updateGuiMode ( GuiMode mode)
protectedvirtual

Update the views GUI based on the set GuiMode (Clinical=0, Research=1).

Parameters
modeThe new mode (Clinical=0, Research=1).

Implements DISPLIB::AbstractView.

Definition at line 400 of file averagelayoutview.cpp.

◆ updateProcessingMode()

void AverageLayoutView::updateProcessingMode ( ProcessingMode mode)
protectedvirtual

Update the views GUI based on the set ProcessingMode (RealTime=0, Offline=1).

Parameters
modeThe new mode (RealTime=0, Offline=1).

Implements DISPLIB::AbstractView.

Definition at line 412 of file averagelayoutview.cpp.

◆ updateViewport()

void AverageLayoutView::updateViewport ( )

Update the viewport. This, e.g., necessary if this widget was set to a QDockWidget which changes its floating state.

Definition at line 104 of file averagelayoutview.cpp.

Member Data Documentation

◆ m_pAverageLayoutView

QPointer<QGraphicsView> DISPLIB::AverageLayoutView::m_pAverageLayoutView
protected

View for 2D average layout scene.

Definition at line 278 of file averagelayoutview.h.

◆ m_pAverageScene

QSharedPointer<AverageScene> DISPLIB::AverageLayoutView::m_pAverageScene
protected

The pointer to the average scene.

Definition at line 272 of file averagelayoutview.h.

◆ m_pChannelInfoModel

QSharedPointer<DISPLIB::ChannelInfoModel> DISPLIB::AverageLayoutView::m_pChannelInfoModel
protected

Channel info model.

Definition at line 274 of file averagelayoutview.h.

◆ m_pEvokedSetModel

QSharedPointer<DISPLIB::EvokedSetModel> DISPLIB::AverageLayoutView::m_pEvokedSetModel
protected

The data model.

Definition at line 273 of file averagelayoutview.h.

◆ m_pFiffInfo

QSharedPointer<FIFFLIB::FiffInfo> DISPLIB::AverageLayoutView::m_pFiffInfo
protected

FiffInfo for currently loaded file.

Definition at line 276 of file averagelayoutview.h.

◆ m_qMapAverageActivation

QSharedPointer<QMap<QString, bool> > DISPLIB::AverageLayoutView::m_qMapAverageActivation
protected

Average activation status.

Definition at line 281 of file averagelayoutview.h.

◆ m_qMapAverageColor

QSharedPointer<QMap<QString, QColor> > DISPLIB::AverageLayoutView::m_qMapAverageColor
protected

Average colors.

Definition at line 280 of file averagelayoutview.h.

◆ m_scaleMap

QMap<qint32, float> DISPLIB::AverageLayoutView::m_scaleMap
protected

The current scaling map.

Definition at line 282 of file averagelayoutview.h.


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