Re: [LAU] Creating evenly spaced sample chains?

From: Joel Roth <joelz@email-addr-hidden>
Date: Sat May 04 2013 - 19:43:12 EEST

Janus wrote:
>
> Greetings,
>
> I'd like to chain samples into one new sample such that each input
> sample starts at a multiple of a given time value in the output sample
> (basically an evenly spaced concatenation). All input samples share the
> same format but differ in length. If a sample is longer than the given
> time interval it's tail shall be cut off (overwritten by the next one),
> if it's shorter, silence shall be added to it's end.
>
> Do you know of a tool or can you think of a command pipeline that would
> establish this (putting the samples on the grid in a DAW to export the
> result is too much work and also would make me feel stupid!)?
>
> I tried sox so far but it seems that it's not up to the task.

Ecasound can do it, too.

If the fixed spacing is "interval", this could work (untested)

ecasound \
-a:1 -i:playat,<interval*0>,select,0,interval,sample1.wav \
-a:2 -i:playat,<interval*1>,select,0,interval,sample2.wav \
-a:3 -i:playat,<interval*2>,select,0,interval,sample3.wav \
-a:4 -i:playat,<interval*3>,select,0,interval,sample4.wav \
... \
-a:1,2,3,4,... -o outputfile.wav
 
Cheers,

-- 
Joel Roth
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@email-addr-hidden
http://lists.linuxaudio.org/listinfo/linux-audio-user
Received on Sat May 4 20:15:04 2013

This archive was generated by hypermail 2.1.8 : Sat May 04 2013 - 20:15:04 EEST