1$nyquist plug-in 2$version 4 3$type process 4$preview linear 5$name (_ "Notch Filter") 6$manpage "Notch_Filter" 7$debugbutton false 8$action (_ "Applying Notch Filter...") 9$author (_ "Steve Daulton and Bill Wharrie") 10$release 2.3.0 11$copyright (_ "Released under terms of the GNU General Public License version 2") 12 13;; notch.ny by Steve Daulton and Bill Wharrie 14 15;; Released under terms of the GNU General Public License version 2: 16;; http://www.gnu.org/licenses/old-licenses/gpl-2.0.html 17;; 18;; For information about writing and modifying Nyquist plug-ins: 19;; https://wiki.audacityteam.org/wiki/Nyquist_Plug-ins_Reference 20 21 22$control frequency (_ "Frequency (Hz)") float-text "" 60 0 nil 23$control q (_ "Q (higher value reduces width)") float-text "" 1 0.1 1000 24 25(cond 26 ((< frequency 0.1) (_ "Frequency must be at least 0.1 Hz.")) 27 ((>= frequency (/ *sound-srate* 2.0)) 28 (format nil (_ "Error:~%~%Frequency (~a Hz) is too high for track sample rate.~%~%~ 29 Track sample rate is ~a Hz.~%~ 30 Frequency must be less than ~a Hz.") 31 frequency 32 *sound-srate* 33 (/ *sound-srate* 2.0))) 34 (T (notch2 *track* frequency q))) 35