69 const QPointF &channelPosition,
120 painter->setRenderHint(QPainter::Antialiasing,
true);
123 painter->setOpacity(0.20);
143 pen.setColor(Qt::red);
145 pen.setCosmetic(
true);
147 QFont f = painter->font();
151 painter->setPen(pen);
179 for(
int dataIndex = 0; dataIndex <
m_lAverageData.size(); ++dataIndex) {
184 const double* averageData =
m_lAverageData.at(dataIndex).second.first;
190 double xStep =
boundingRect.width() /
static_cast<double>(totalCols);
196 pen.setStyle(Qt::SolidLine);
204 pen.setCosmetic(
true);
205 painter->setPen(pen);
207 for(
int i = 0; i < totalCols; ++i) {
213 if(val > halfH) val = halfH;
214 else if(val < -halfH) val = -halfH;
217 path.lineTo(QPointF(xPos, centerY - val));
220 painter->drawPath(path);
238 double xStep =
boundingRect.width() /
static_cast<double>(totalCols);
241 pen.setStyle(Qt::SolidLine);
242 pen.setColor(Qt::red);
244 pen.setCosmetic(
true);
245 painter->setPen(pen);
259 painter->drawPath(path);
Contains the declaration of the AverageSceneItem class.
Declaration of the ScalingView Class.
Old fiff_type declarations - replace them.
2-D display widgets and visualisation helpers (charts, topography, colour maps).
float getScalingValue(const QMap< qint32, float > &qMapChScaling, int iChannelKind, int iChannelUnit)
virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
void mousePressEvent(QGraphicsSceneMouseEvent *event)
QRectF m_rectBoundingRect
void paintStimLine(QPainter *painter)
QList< QPair< QString, RowVectorPair > > m_lAverageData
QMap< qint32, float > m_scaleMap
void paintAveragePath(QPainter *painter)
QPair< int, int > m_firstLastSample
void sceneUpdateRequested()
int m_iTotalNumberChannels
QPointF m_qpChannelPosition
AverageSceneItem(const QString &channelName, int channelNumber, const QPointF &channelPosition, int channelKind, int channelUnit, const QColor &color=Qt::yellow)
void mouseReleaseEvent(QGraphicsSceneMouseEvent *event)
QMap< QString, bool > m_qMapAverageActivation
void setDefaultColor(const QColor &viewColor)
QRectF boundingRect() const
QMap< QString, QColor > m_qMapAverageColor