I have a plot working now with QwtPlotSpectrogram using my own data class for continuous interpolated values.

The documentation on QwtPlotSpectrogram is fairly brief, so I've been following the example/Spectrogram. I decided to try turning on contour lines and added initialization of the contour levels using setContourLevels with code similar to this...

Qt Code:
  1. QList<double> contourLevels;
  2. for ( double level = 0.5; level < 110.0; level += 15.0 )
  3. contourLevels += level;
  4. spectrogram->setContourLevels( contourLevels );
  5.  
  6. spectrogram->setDefaultContourPen( QPen() );
  7. spectrogram->setDisplayMode(QwtPlotSpectrogram::ContourMode, true);
To copy to clipboard, switch view to plain text mode 

This follows the example code pretty closely. I use a QwtPlotGrid as well.

I don't see the lines drawn over my spectrogram plot, so I tried disabling ImageMode and only enabling the ContourMode, but this produced nothing.

I'm sure I'm missing something simple. I'm not subclassing QwtPlotSpectrogram- only the data class. Everything is working with the ImageMode and my spectrogram plot, except the countour lines.

thanks in advance...