Is there an Open-Source Compressor?

Hey guys,

Can someone suggest an open-source (realtime) compressor (for dynamic compression)?

Cheers!

I’ve used SimpleComp for a prior project. It can be tricky to find because it appears to be one of those old-ish creaky bits of C++ passed around places like MusicDSP. It sounds decent and works well enough if you’re looking for a generic digital compressor.

I have it in one of my repositories:

Basic wrapper for JUCE:

2 Likes

Thanks @jonathonracz. Is the license on this same as the whole project (GPL 3)?

Update:

  • Ooops! Sorry, somehow I didn’t see the header.
1 Like

For future reference, I am more than happy to personally grant license to let people use chunks of code from my projects (which, SimpleComp is not mine, but something like the JUCE implementation) under more permissive licenses, I just throw the whole thing under GPLv3 as a fast way of open-sourcing without letting someone sell my work outright. There’s a lot of stuff I’d like to factor into an Apache-licensed module…

2 Likes

You can compile Faust examples to C++
The resulting C++ in most cases I believe is under a non-restrictive MIT-like license but some of the examples might generate GPLv3 C++ code. Compressor is non GPL I believe.

Faust online compiler: https://faust.grame.fr/onlinecompiler/
Faust examples to be compiled (compressor is in dynamics folder): https://github.com/grame-cncm/faust/tree/master-dev/examples

2 Likes

Thanks @mtytel! Helm is awesome! Thanks for building and releasing it open-source! Such a great example and high bar to follow. Cheers!

1 Like

Audio Toolkit has lots of building blocks for dynamic processing, and there are a few plugins using it.

1 Like

The IEM plug-in suite has a compressor, open source and under GPLv3. Feel free to use it :slight_smile:

2 Likes

Thanks @Matthieu_Brucher! This looks interesting. Either I haven’t seen AT before, or I had the wrong impression it’s only iOS (what was the name of that open-source DSP framework that was just iOS?).

So there isn’t a full compressor, but there are the building blocks for it (probably envelope detection, etc.)? How would you recommend approaching creating a sidechain-able compressor with Audio Toolkit? (just as high-level guidelines)

Thanks @danielrudrich! I hope I can find something permissive for commercial use, but I can always use the example. Cheers!

Yes, there is another project apparently, but it has nothing to do with ATK (which can be built for iOS).
There is an example (but not for JUCE) available on one of my repositories: https://github.com/mbrucher/ATK-plugins/blob/master/ATKSideChainCompressor/ATKSideChainCompressor.cpp

1 Like

There isn’t much sorcery behind coding your own compressor, especially with that amount of free material available in books, the internet,… . Please feel free to get inspired by the code :slight_smile:

Thanks. No sorcery expected. Just time.

The book “Designing audio effect plug-ins in c++” by Will Pirkle has a chapter about compressors and dynamics processing. It provides not only code examples but also theoretical background on the subject. Highly recommended.

1 Like

In my last ADC presentation, I talked about a simple compressor algorithm, and I shared the code on the associated topic : [ADC17] Fifty Shades of Distortion (extra files + homework part 1)

3 Likes

Hi Jonathon, sorry if this comes across as pedantic, but GPL3 doesn’t prevent people selling your work, it just means they can’t sell a closed-source fork. If you want to prevent people selling your work, you need a non-commercial license like a CC NC license

That closed-source fork case is really what I’m talking about when I use the imprecise language of “selling” my work.

Most of what I do in open source is for portfolio and skills building, so I see any properly attributed spreading of my work as germination for my future career - which is why I’m open to giving out portions under permissive licenses and want to refactor lots of things into permissively licensed libraries.

1 Like

Cool. I just wanted to make sure you (or anyone else reading this thread) didn’t put their work under the GPL thinking it means “no commercial use” and get a nasty surprise.

And thanks for sharing your work BTW :+1:

And since Tuesday, there is now a JUCE version (not that the DSP code changed).

Further thread drift, but Creative Commons don’t recommend their licenses for code.

1 Like