View Full Version : Simple command-line wave editing?
Matthew
30th September 2005, 03:20
I'd like to be able to do some simple wave editing at the command-line, on 16 bit stereo files at the sample level. Specifically:
-Obtain the number of samples in the file
-Add some silent samples
-Trim some samples
I know I can do this all myself fairly easily if the file contains only the 44 byte header+samples, but that isn't always the case.
Any suggestions? Thanks :)
Rockaria
30th September 2005, 05:08
You can try this delaycut (http://jsoto.posunplugged.com/audiotools.htm) which works on both gui and cli mode and I found very useful on wav, mpa dts and ac3 formats.
Matthew
30th September 2005, 05:33
I already use delaycut for mp2/ac3, I forgot it supported PCM :o
I don't think the cutting features are accurate enough (I want them at the sample level), but it does report the number of samples in the log. That at least me a starting point to add/delete bytes in intervals of 4 and then test the length to check I haven't just removed a tag.
Thanks :)
Rockaria
30th September 2005, 05:56
Ouch, :p it supports on msec level!
44100 / 1000 == 4.41 samples/msec
Matthew
30th September 2005, 07:14
Come to think of it, cutting to the nearest millisecond will do :)
mimungr
1st October 2005, 00:00
sox can cut at the sample level.
Matthew
1st October 2005, 09:03
Thanks for the suggestion, I may well end up using that app :)
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.