After squaring Lt and Rt, I add the squared values and do mono smoothing from that point on. Alternately I could take the greater of the Lt or Rt squared values at that same point. Might add that option some time. I decided to do the Lt+Rt summing because it seemed a "more idealized" rms compression-- Even though it is possible that summing compression might not work as good as "greater of the two" compression on real music.
Ideally I'd prefer to calc the Lt and Rt envelopes completely independent, up to the point of either summing or "greater of the two" right before calculating the gain. But the smoothing in this rms comp is "fairly cpu hungry" and I didn't want to "double the load" by duplicating the entire envelope chains.
This one has sidechain highpass filters. Seems those make the most sense before everything else, and highpass of the "greater of the two channels" or highpass of the sum of the two channels probably would not work as desired. So the Lt and Rt have their own highpass filters.
Then I use a small allpass network for a "bass frequency hilbert" to reduce bass ripple. I suspect the allpass nets probably wouldn't work so great unless there are separate allpass networks, one for the Lt and one for Rt.
The Lt allpass has two phase shifted outputs. Squaring each output and adding them together is what reduces Lt bass ripple. It is the same story with the two Rt allpass outputs.
So it is stereo until the squaring summing step after the allpass filters, and mono smoothing afterwards--
MonoSquaredSamp = 0.25 * ((AP_Lt_1^2 + AP_Lt_2^2) + (AP_Rt_1^2 + AP_Rt_2^2));


