Community Forums Archive

Go Back

Subject:Batch Fade in & Out
Posted by: rsp
Date:7/2/2005 1:59:57 AM

Have around 100 files which need a 1 or 2 second fade in & out
Tried the batchconvertor but adding Fade In or Fade Out it says "cannot change preset".

Anyone know a solution to save a lot of manual work?

Subject:RE: Batch Fade in & Out
Reply by: Iacobus
Date:7/9/2005 11:48:52 AM

The problem with this is that Sound Forge will assume you want to apply the fades to the entire file, not just 1 or 2 seconds at the beginning and end of the file.

Iacobus
-------
RodelWorks - Original Music for the Unafraid
Buy Instant ACID by JohnnyRoy and mD!
mD at ACIDplanet

Subject:RE: Batch Fade in & Out
Reply by: rsp
Date:7/9/2005 1:58:17 PM

Thanks for your reply - can a script do the trick or will it also apply to the entire file?


Subject:RE: Batch Fade in & Out
Reply by: _TJ
Date:7/9/2005 11:14:36 PM

You can do this with a script. When you use effects in Scripts, one of the parameters that you pass in defines the range to be processed.

Here's the basic code for putting a 1 second fade in at that start of a file, and a 1 second fade out at the end.


Int64 fadesize = file.SecondsToPosition(1.0);
SfAudioSelection asel = new SfAudioSelection(0, fadesize);
file.DoEffect("Fade In", 0, asel, EffectOptions.EffectOnly);
file.WaitForDoneOrCancel();

asel = new SfAudioSelection(file.Length - fadesize, fadesize);
file.DoEffect("Fade Out", 0, asel, EffectOptions.EffectOnly);
file.WaitForDoneOrCancel();


tj

Message last edited on7/9/2005 11:16:28 PM by_TJ.
Subject:RE: Batch Fade in & Out
Reply by: rsp
Date:7/11/2005 1:40:17 AM

Thanks for the basic script - will try and get this to work

Subject:RE: Batch Fade in & Out
Reply by: _TJ
Date:7/12/2005 8:15:54 PM

No problem. Stop by the scripting forum if you get stuck.
tj

Go Back