ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

How to creat "floaty" camera movements?

COW Forums : Adobe After Effects

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Colin Carver
How to creat "floaty" camera movements?
on Aug 3, 2012 at 10:31:15 pm

Example video: https://vimeo.com/2693546

I want to create a floating type of camera movement, similar to the one used in the video above (although I'd like to have mine a little softer/smoother). Can anyone explain to me in not-to-technical terms how I can accomplish something like this?

I'm fairly sure it has something to do with the Wiggle expression, but after some experimentation I can't get smooth motion, and I'd like some kind of easing to stop sudden jerky movements.

Colin.


Return to posts index

John Cuevas
Re: How to creat "floaty" camera movements?
on Aug 3, 2012 at 11:09:31 pm

Here's the formula I use on my camera taken from an expression originally written by Dan Ebberts. Because AE recalculates expressions on each frame a really smooth ramp up and down for wiggle is actually pretty difficult, the brilliance of this expression though that does exactly that though, create smooth ramps up and down for wiggle.:

Create a null and add 2 sliders and name them Frequency & Amplitude. Add this expression to the position property of your null and then parent the camera position to the null so that the wiggle is added to it. Just keyframe the null and you are all set:

if (freq.numKeys > 0){
accum = 0;
v0 = freq.valueAtTime(0);
t0 = 0;
i = 1;
while (i <= freq.numKeys){
t = freq.key(i).time;
if (t < time){
accum += (v0 + freq.key(i).value)*(t - t0)/2;
v0 = freq.key(i).value;
t0 = t;
if (i == freq.numKeys){
accum += (time - t0)*v0;
}
}else{
accum += (freq + v0)*(time - t0)/2;
break;
}
i++;
}
}else{
accum = freq*time;
}
wiggle(1,amp,1,.5,accum);


Johnny Cuevas, Editor
Thinkck.com

"I have not failed 700 times. I have succeeded in proving that those 700 ways will not work. When I have eliminated the ways that will not work, I will find the way that will work."
---THOMAS EDISON on inventing the light bulb.


Return to posts index

Colin Carver
Re: How to creat "floaty" camera movements?
on Aug 3, 2012 at 11:28:52 pm

Thank you for the quick reply, John. This sounds just like what I'm looking for but I have a problem. I've created the two sliders in the null object as you said, and added the expression to the null's position property, however I'm getting an error message:

After Effects warning: Class ‘global’ has no property or method named ‘freq’ Expression disabled.

Error occurred at line 1.
Comp: ‘float’
Layer: 1 (‘Null 1’)
Property: ‘Position’


I assume that I have to pickwhip parts of the expression to the Frequency and Amplitude sliders in the null, but not really knowing anything about expressions I don't know which part!

Colin.


Return to posts index


John Cuevas
Re: How to creat "floaty" camera movements?
on Aug 3, 2012 at 11:44:19 pm

My bad, I didn't copy the entire expression. If you name your sliders "Frequency" & "Amplitude", you won't have to pickwhip to them, this will connect right to it.. And just in case I messed up anything else, here's a project with the wiggle and a camera.

4493_wiggleexpression.aep.zip

freq = effect("Frequency")("Slider");
amp = effect("Amplitude")("Slider");

if (freq.numKeys > 0){
accum = 0;
v0 = freq.valueAtTime(0);
t0 = 0;
i = 1;
while (i <= freq.numKeys){
t = freq.key(i).time;
if (t < time){
accum += (v0 + freq.key(i).value)*(t - t0)/2;
v0 = freq.key(i).value;
t0 = t;
if (i == freq.numKeys){
accum += (time - t0)*v0;
}
}else{
accum += (freq + v0)*(time - t0)/2;
break;
}
i++;
}
}else{
accum = freq*time;
}
wiggle(1,amp,1,.5,accum);


Johnny Cuevas, Editor
Thinkck.com

"I have not failed 700 times. I have succeeded in proving that those 700 ways will not work. When I have eliminated the ways that will not work, I will find the way that will work."
---THOMAS EDISON on inventing the light bulb.


Return to posts index

Colin Carver
Re: How to creat "floaty" camera movements?
on Aug 4, 2012 at 12:13:55 am

That's just about perfect, John! Thank you very much for your help. I really appreciate it.

Colin.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]