QtVST: how QtSimpleOverdrive is implemented

A few days ago, I’ve released my first VST plugin. Now it is time to analyze how it works.

Block diagram

The block is really straightforward:

QtSimpleOverdrive block diagram

The oversampled signal is only used for the overdrive, and it composes more than half of the plugin code.

Oversampling impact on spectral content

To analyze the effect of the oversampling, I feed inside the plugin a sinesweep at 96kHz and then I draw a spectrogram of both the input and the output signal.

2x oversampling for the overdrive

If only a 2x oversampling is used, the audio frequency band is filled with alias, which is definitely not good..

8x oversampling

The 8x oversampling has only a some alias in the high frequency sine sweep. It is thus far better than the 2x oversampling.

32x oversampling

Finally, the 32x oversampling is almost perfect. It still has some background noise for the high frequency sine sweep.

Profiling with 8x oversampling

First, some timings. On my laptop with Ubuntu, the test case (2 millions samples for a sin sweep at 96kHz) takes 17s with a 2x oversampling, 20s for a 8x oversampling and finally 54s for an 32x oversampling. On Windows, those timings are respectively 14s, 22s and 63s.

Profil for QtSimpleOverdrive

The profil shows that the main cost is due to the exponential function. It is used because two diodes are used in the analog model of this overdrive. A circuit with no exponential would be faster, but it is the diode’s behavior that is caracteristic of this sound.


Clearly, going from an 8x to 32x oversampling is far more costly than from 2x to 8x. 8x seems a good compromise between performance and quality. 32x may only be used for offline rendering.

I’ve made a small presentation on this subject that is available on SlideShare.

Buy Me a Coffee!
Other Amount:
Your Email Address:

12 thoughts on “QtVST: how QtSimpleOverdrive is implemented”

  1. Hi Matthieu,

    please could you synchronize your current code changes to your public git repository? I would like to learn how your polyphase filter is implemented in C++.


    1. Hi Dan,

      For the moment, I’m waiting a little bit to see whether or not people are interested in the code. It’s a lot of time to implement everything in a adequate manner between my fulltime job and my family, so I’d like to see the interest before I make it available under the GPL 😉
      You are the first to be interested, so it’s a start toward the release of the code 😉

  2. Hi Matthieu,
    Very cool that you’ve chosen QT for your GUI. I’d be very interested in seeing how you got it working. Thanks 🙂

Leave a Reply