Audio enter and processing – suggestions

Audio enter and processing – suggestions


    After studying Corion‘s reply I assumed that it may be sooner to let the command line do the FFT and move that knowledge to perl. I modified Corion‘s command-line to pipe into sox which might do fundamental FFT. I’ve additionally modified the ffmpeg choices to output in sox format -f sox from studying my soundcard #0 -i hw:0 with alsa, thusly:

ffmpeg -hide_banner -loglevel error -nostats -f alsa -i hw:0 -t 30 -ac + 1 -ar 44100 -f sox - | sox -t sox - -n stat -freq

Also, see this: https://www.linuxquestions.org/questions/linux-software-2/why-does-sox-stat-freq-give-me-different-data-multiple-times-927589/ for instance.

Alternatively, you need to use Corion‘s code to learn uncooked audio bytes and plug them into PDL::FFTW3 to get FFT with a state-of-the-art C library (FFTW3).

Following the latter route, you clearly have extra management on what processing to do, albeit slower (hmm benchmarks?).

The different route is to exchange sox with customized C code (primarily based on FFTW3 library) to do the FFT and some other processing you need nearer to the {hardware}.

Finally, there are many different command-line-based software program in Linux to construct a processing pipeline to your wants.

Last however not least: PureData (PD) https://puredata.information/

bw, bliako

HI-FI News

by way of PerlMonks http://perlmonks.org/

November 22, 2023 at 01:02PM