46 #include <QGraphicsPathItem>
47 #include <QGraphicsView>
58 using namespace DISPLIB;
59 using namespace Eigen;
60 using namespace RTPROCESSINGLIB;
68 , m_pGraphicsItemPath(new QGraphicsPathItem())
70 , m_iNumberHorizontalLines(4)
71 , m_iNumberVerticalLines(3)
73 , m_iDiagramMarginsHoriz(5)
74 , m_iDiagramMarginsVert(5)
77 , m_iCutOffMarkerWidth(3)
90 if(operatorFilter.getCoefficients().cols() == 0)
102 QWidget * pQwidgetty(
dynamic_cast<QWidget*
>(parent()));
103 m_cPenColor = pQwidgetty->palette().text().color();
115 const QString& filtername)
128 int fMax = samplingFreq/2;
136 QGraphicsTextItem * text = addText(filtername, QFont(
"Times",
m_iAxisTextSize));
142 QPen pen(Qt::DotLine);
181 switch(FilterKernel::m_filterTypes.indexOf(
m_pCurrentFilter.getFilterType())) {
183 pos = ((double)
m_iCutOffLow / (
double)fMax) * numberCoeff;
201 pos = ((double)
m_iCutOffLow / (
double)fMax) * numberCoeff;
225 float numberCoeff = coefficientsAFreq.cols();
226 float dsFactor = numberCoeff/
m_qvView->width();
229 for(
int i = 0; i<coefficientsAFreq.cols(); i++) {
230 if(std::abs(coefficientsAFreq(i)) > max) {
231 max = std::abs(coefficientsAFreq(i));
235 coefficientsAFreq = coefficientsAFreq / max;
247 for(
int i = 0; i < numberCoeff; i++) {
255 path.lineTo(path.currentPosition().x()+(1/dsFactor),y);
257 path.lineTo(path.currentPosition().x()+1,y);