What do you mean by "shaping"?
Levelling compression means manipulating the dynamics so the instrument track appears more even in terms of loudness. While levelling also affects the character of the sound, you're trying to avoid audible compression. When levelling, you're usually concerned with macro dynamics
, i.e. getting different segments or phrases at the approximate same level.
Shaping is all about audible compression. Audible in this case doesn't mean artifacts such as pumping and breathing, but that you're trying to manipulate micro dynamics
, e.g. the transients or tails of individual notes or parts of the signal. Shaping could mean controlling the tail of a kick drum, adding snap to a snare drum, controlling the attack of a guitar, etc.
Some of the techniques used in levelling and shaping are the same, but they're used for different reasons - and the devil's in the detail. Think about the intention
when you're compressing.
A lot of people are in fact doing shaping compression with the intention of levelling, which means they're missing the point and getting the worst of both.
When dealing with vocals and real recorded instruments it's not uncommon to use serial compression, e.g. compressing the signal twice, with one doing levelling and the other doing shaping duties. One of these compressors could be a hardware tracking device. The best of both worlds, as long as you know the when and the how. But that's a different story.
And when saying compression in EDM is almost never about loudness, is it because the sounds already are static? Is it because its sample based, and therefore doesn't have variable peaks like in recorded music?
Anything programmed is level controllable in other and usually better ways, such as MIDI velocity.
The same is actually also true for shaping, if you are the producer and not just the mix engineer on an exported project: sample/waveform manipulation, enveloping (ADSR), etc. Compression can be used as yet another tool for shaping the sound, but rarely does it make much sense as a pure levelling tool when it comes to EDM.
Would you prevent using subcompression and mixbusscompression in EDM?
No, compression can be a great tool. The trick is to know when and how to use it.