Code: Select all
;Reducing the samples per second should improve the performance and decrease ;the accuracy of the labels. Increasing the samples per second will do the ;opposite. The more samples checked, the longer it takes. The more samples ;checked, the more precisely the program can place the silence labels. ;my-srate-ratio determines the number of samples in my-s. Set the number after (snd-srate s) ;higher to increase the number of samples. (defun my-s (s-in) (setq my-srate-ratio (truncate (/ (snd-srate (mono-s s-in))(/ *sound-srate* 100)))) (snd-avg (mono-s s-in) my-srate-ratio my-srate-ratio OP-PEAK) )
This plug-in is very fast - on my machine, on the order of four seconds per hour of audio at 44100. If it were more accurate and took twice as long I would be satisfied with the time consumption. How do I "increase the number of samples"?Set the number after (snd-srate s) higher to increase the number of samples.
You and I have both customized this so I have attached the entire plug-in source.