|
|||||||
![]() |
|
|
Thread Tools |
|
|
#1 |
|
DriverHeaven Addict
Join Date: Dec 2002
Posts: 259
Rep Power: 0 ![]() |
Automatic Gain Control (AGC)
Well, I have writed a pluging to avoid clipping produced in any effect. The method is very very simple: Just attenuates the signal a little each time a clip is detected. There are several things:
1.- It was designed to be intercalated between ecualizer and epilog, with the purpose of automatically reduce the gain until the maximum value wich don't produce clipping. 2.- It has a "memory" of one sample. This is, looks at the inmediately previous (stored in a variable) sample and if it is grater than 0.24 [0.25 = clip] reduce the gain in ~0.3 dB. There is no noticiable audio effect. 3.- It is not a compressor or a limiter: It reduces the gain for all the sound. This is, no distortion is produced. 4.- The pluging only reduces gain, and this gain remain untouched 'per seculam seculorum', although the ecualizer parameters are changed. 5.- There is a control in the tweak window to reset gain to 0dB. Could it be possible to "link" or "sincronize" this control with any change made in the ecualizer tweak window (via the dll). Here you have the dll: agc.kxl (see next post) (compiled for the 3531 version) Last edited by eyagos; Mar 27, 2003 at 11:14 PM. |
|
|
|
|
|
|
|
DriverHeaven Addict
Join Date: Dec 2002
Posts: 259
Rep Power: 0 ![]() |
Sorry, I have have put the incorrect version. Download this one and forget the other: agc_1.kxl
|
|
|
|
|
|
|
|
DriverHeaven Addict
Join Date: Dec 2002
Posts: 259
Rep Power: 0 ![]() |
If someone has proved the AGC, can you please post some coments??
|
|
|
|
|
|
#4 |
|
DriverHeaven Newbie
Join Date: Dec 2002
Location: Ottawa, Ontario, Canada
Posts: 19
Rep Power: 0 ![]() |
AGC
Nice work on this plugin... it works well for me when tweaking the EQ on the final output to mains... just eq away and let the plugin take care of any clipping may occur, perfect!
Nice Work Sur |
|
|
|
|
|
|
|
DriverHeaven Addict
Join Date: Dec 2002
Posts: 259
Rep Power: 0 ![]() |
The abobe link doesn't work. You can download this plugin from my Web Site:
KXPlugins (sorry, only available in spanish) |
|
|
|
|
|
|
|
|
DriverHeaven Addict
Join Date: Dec 2002
Posts: 259
Rep Power: 0 ![]() |
Hi LeMury.
Yes, that is "the other version". I mean, that is the first version I writed and, by mistake, it is the one included in the .da version you can download from the Web. And yes, it has two temporal registers unused/unneeded, so the one you posted is better. But the .kxl version is different (as I said at the top this was my mistake): * In the .kxl version you calculate the max value between the two stereo channels to detect clips. * And in the other version (the one you use) you calculate the mean value between the two stereo channels to detect clips. Both options are very close, but if the stereo is not balanced, the mean value does not assure you that there is no clip in the louder channel. So, the code used in the .kxl version is this (two code lines and two registers more): Quote:
And of course, I'll not get angry if you modify the code. In the other hand, I'll be very pleased. Regards, and keep on the wave. |
|
|
|
|
|
|
#7 |
|
DH Senior Member
Join Date: Jan 2003
Location: The Netherlands
Posts: 1,930
Rep Power: 62 ![]() ![]() ![]() ![]() |
Hi Eyagos,
Thank you for confirming. Yes I noticed your .kxl version functioned different/better. Nice work! >I have noticed that this code can be optimized too, saving one temporal register ('tmp' register is not >needed, and 'tmp4' could be used instead). Yes, and you can also re-use 'x1' , saving 1 more gpr like this: macsn x1, x1, clip, 1 ....etc. >And of course, I'll not get angry if you modify the code. In the other hand, I'll be very pleased. Ah,..ok.. I am very glad about that. Next time I will send you a private message ok? Regards, /LeMury |
|
|
|
|
|
#8 |
|
DriverHeaven Newbie
Join Date: Mar 2003
Location: 52°20'26" N , 9°22'40" E
Posts: 10
Rep Power: 0 ![]() |
Hi...
First, this is a very nice plugin! Thanks eyagos! I'm not well versed in coding plugins, so I've a question. What is the "o_gain" output for? |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
|
|