jav321
25th June 2015, 17:52
Hi,
I am plotting a curve with magnitude in dBs and frequency from 0Hz to 20Khz on linear scale. I generate a simple linear frequency array. Now I want to view my Curve on a typical log scale that is used in audio players. But I don't know how ?
I tried adding this to my code.
QwtLog10ScaleEngine *qwtlog = new QwtLog10ScaleEngine();
plot->setAxisScaleEngine(QwtPlot::xBottom, qwtlog);
This does work but my x axis scale starts at 1E-100 and ends at 1. I want to change its limits so that it goes from 0 to 20KHz like this
http://machrone.home.comcast.net/~machrone/playertest/h10_octave_sweep.gif
Can anyone help me as to what should I do ?
I am plotting a curve with magnitude in dBs and frequency from 0Hz to 20Khz on linear scale. I generate a simple linear frequency array. Now I want to view my Curve on a typical log scale that is used in audio players. But I don't know how ?
I tried adding this to my code.
QwtLog10ScaleEngine *qwtlog = new QwtLog10ScaleEngine();
plot->setAxisScaleEngine(QwtPlot::xBottom, qwtlog);
This does work but my x axis scale starts at 1E-100 and ends at 1. I want to change its limits so that it goes from 0 to 20KHz like this
http://machrone.home.comcast.net/~machrone/playertest/h10_octave_sweep.gif
Can anyone help me as to what should I do ?