i know how to do it, but it is a bit laborious in OS9 and in my existing plug-in i dont fully follow the specs.
given that when i started this the EBU R128 was not even in sight and the struggle between a-weighting and k-weighting was not yet fought out.
i used FFT for both, L-a and L-k... but i might change the k-weighting to IIR or FIR filters, then it will be less labourious (for the cost of more CPU)
note that - just as with stereo to surround matrix conversion or dithering - loudness correction is one of the cases where it would be better to make standalones only, because you can easily use it wrong when you have it as plug-ins.
apropos "stereo". normally you do it per channel, as you say, and that is cool because then you can see and treat the gain per channel. but for the "loudness issue" itself and for normal stereo format (i.e. not encoded surround) you can also work with summed to mono.
the more difficult task today is to find out what certain broadcasters actually want and for what formats, because it is different between compressed and uncompressed, between DTS:Neo and dolby E as well as between german and austrian TV stations. and between music and speech, for that matter.
and relative to inter-samplepeaks? seriously? just substract another -0.3db (or -0.35 for compressed) from the value you should go, and you should be fine.
maybe it shows up here in 6 weeks, but i dont promise a certain order.
as you can guess, i do not play the "monthly" game to annoy you but to force myself to make fresh builds and libraries and correct bugs in the GUI´n stuff. it is about time after 20 years.