Developing a program with LiveCode 7 that has soundboard component where I can queue commercial spots. I can get the audio clips to play and stop, but
I want to also use a fade out control. I have looked high and low but can not find a sample script or any how to's.
I am developing the app for OS X . Just need to be pointed in the right direction. I am using the play audio clip ID xxxx command and play stop command.
Fading out an audio clip
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Re: Fading out an audio clip
Hi timbrian,
How about this
Simon
How about this
Code: Select all
repeat with x = 100 down to 0
set the playLoudness to x
end repeat
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: Fading out an audio clip
Hi Tim,
1. welcome to the forum!
2. To actually hear the fade-out you should add a little wait statement.
Without, well, it will sound like the sound got switched off immediately
Or use something like this:
Best
Klaus
1. welcome to the forum!

2. To actually hear the fade-out you should add a little wait statement.
Without, well, it will sound like the sound got switched off immediately

Code: Select all
repeat with x = 100 down to 0
set the playLoudness to x
wait 2 millisecs with messages
## play with the millisecs value
end repeat
Code: Select all
## fade out in 1 second:
repeat with x = 100 down to 0 STEP 10
set the playLoudness to x
wait 100 millisecs with messages
end repeat
Klaus
Re: Fading out an audio clip
Thanks Simon and Klaus for the help. That did the job!
Tim
Louisville, Ky
Louisville, Ky