Re: [LAU] Discovering file format

From: Lorenzo Sutton <lorenzofsutton@email-addr-hidden>
Date: Sun Sep 20 2015 - 15:03:41 EEST

On 19/09/15 23:12, Will J Godfrey wrote:
> Once again, thanks everyone
>
> As it was only uncompressed files I was looking at 'file' turned out to be the
> simplest and fastest. I simply redirected the output to create a text file, then
> picked it up with kwrite.

I think soxi (part of sox) should also have been mentioned... then you
could quickly hack something like this:

for f in *.wav
do
     SR=$(soxi -r "$f")
     BITS=$(soxi -b "$f")
     printf "%-20s %s bits, %s Hz\n" "$f" "$BITS" "$SR"
done

Sample output:

agogo_h.wav 16 bits, 44100 Hz
agogo_lo.wav 16 bits, 44100 Hz
bell_tree.wav 16 bits, 44100 Hz
...

_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@email-addr-hidden
http://lists.linuxaudio.org/listinfo/linux-audio-user
Received on Sun Sep 20 16:15:01 2015

This archive was generated by hypermail 2.1.8 : Sun Sep 20 2015 - 16:15:01 EEST