Gating audio signals

Michael Gary Dean's icon

Hello all.

I'm trying to figure out how to effectively build a gate. More explicitly, every time my input audio reaches an amplitude higher than a certain number, the gate opens to allow the signal through. My current patch pasted here seems to do that, but it is slow, inaccurate, and ineffective. I've searched the forums to try to find a solution to similar questions but I am still stuck. If anyone would mind looking at my patch I would really appreciate it.

Max Patch
Copy patch and select New From Clipboard in Max.

Thanks,
Mike

Floating Point's icon

try average~ instead of peakamp~
also keep it in audio signal domain

Max Patch
Copy patch and select New From Clipboard in Max.

here's a start-- maybe instead of using gate~ have some sort of ramped gain control (using line~ and *~)

Trond Lossius's icon

Hi, you could check the code for the noise gate module in Jamoma (www.jamoma.org).

Noob4Life's icon
Max Patch
Copy patch and select New From Clipboard in Max.

thresh~ is perfect for what you describe. many different ways to hook it up, too(you could put average~ into this instead of thresh~ and try different modes of average~). keeping it completely signal-domain as mentioned before is best for speed/efficiency/accuracy:

hope it helps.
________________________________
*Never fear, Noob4Life was never here!*

Michael Gary Dean's icon

As always, thank you very much max community. I will study all your suggestions and hopefully refine my solution.

Merry Xmas!

M.