This content has been marked as final.
Show 2 replies
-
1. Re: Expression question: keep adding to value
Dan Ebberts Oct 31, 2011 11:22 AM (in response to Andy Bay)This Position expression should work. Adjust mult to set the sensitivity (how much it moves in response to the audio) and minVal to set how much it moves when there is no audio.
mult = 10;
minVal = 5;
L = thisComp.layer("Audio Amplitude");
aud = L.effect("Both Channels")("Slider");
accum = 0;
for (f = timeToFrames(inPoint); f <= timeToFrames(); f++){
accum += Math.max(aud.valueAtTime(framesToTime(f)),minVal);
}
value + [0,0,accum*mult]
If you have separated the Camera's dimensions, change the last line to this to make it suitable for Z Position:
value + accum*mult
Dan
-
2. Re: Expression question: keep adding to value
Andy Bay Oct 31, 2011 11:34 AM (in response to Dan Ebberts)OMG, Dan you are the man!
I have no idea of what half of those things included do, but it works!


