here is a solution to pad a track while mixing with another track.
Sox : merge two audio files with a pad
$ sox short.ogg -p pad 6 0 | sox - -m long.ogg output.ogg
How to use this command mixing multiple tracks?
For example
audio1.wav (no pad)
audio2.wav (2s pad)
audio3.wav (2s pad)
audio4.wav (3s pad)
pad 6 0prepends 6 and appends 0 seconds of silence, so I assume you only want to prepend silence.You can do this with a
whileloop, for example inbash:I would suggest keeping the files uncompressed until your done processing.
Be careful of clipping when mixing, one way to avoid it is to apply
-6dBgain to both signals and normalize after, e.g.: