[linux-audio-dev] Length of a soundfile in a script

Erik de Castro Lopo erikd-lad at mega-nerd.com
Thu Jul 8 07:14:30 UTC 2004


On Wed, 7 Jul 2004 22:34:58 -0600
Hans Fugal <hans at fugal.net> wrote:

> I thought sox might be able to do it but I don't see it if it's there. I
> want to know how long (in time) an audio file is. 

On my machine:

    erikd at coltrane > sndfile-info Sound/HelpDesk.wav | grep ^Duration
    Duration    : 00:00:41.616

The sndfile-info program is part of libsndfile. In Debian it gets
installed when you install the sndfile-programs package.

Erik
-- 
+-----------------------------------------------------------+
  Erik de Castro Lopo  nospam at mega-nerd.com (Yes it's valid)
+-----------------------------------------------------------+
Reporter: "What do you think of Western Civilisation?"
M.K. Gandhi: "I think it would be a good idea."



More information about the Linux-audio-dev mailing list