Activity › Forums › Adobe After Effects Expressions › slider control for wiggle…can’t figure it out
-
slider control for wiggle…can’t figure it out
Posted by Doug Nash on May 18, 2008 at 7:13 pmI don’t know why this is so hard for me to figure out. I must be overlooking something simple.
I want to add a wiggle expression to a camera, to approximate a hand-held feel. But I want to be able to increase and decrease that random movement at will. So, I assume I need to use the “Slider Control” effect, correct? But I just can’t get this to work right.
Can someone please give me a push in the right direction?
I’ve searched on this forum, but couldn’t find anything that would help me.
Thank you!
Robin g Davids replied 16 years, 1 month ago 4 Members · 5 Replies -
5 Replies
-
Mike Clasby
May 18, 2008 at 9:19 pmAdd a Null (Layer>New>Null Object). Put Effect>Expression Control>Slider Control on the Null.
Add you wiggle expression to the camera’s position (Copy the expression, Alt-click the Position Stopwatch, Paste, click outside the box). Typical wiggle expression follows:
wiggle (5,50)
Then highlight the 5 (frequency) or the 15 (amplitude) and pickwhip to the slider on the NULL to get an expression like this:
w = wiggle(thisComp.layer(“Null 1”).effect(“Slider Control”)(“Slider”),15)
Now the slider controls the frequency so you can keyframe from zero to whatever you want.
For a camera shake you might want just wiggle the x and y, the original expression would look like this:
w = wiggle(5,15);
[w[0],w[1], value[2]]This modified from Dan page here:
https://www.motionscript.com/design-guide/wiggle-1-dimension.html
and linked to the slider, this:
w = wiggle(thisComp.layer(“Null 1”).effect(“Slider Control”)(“Slider”),15);
[w[0],w[1], value[2]]To put a slide on the amplitude of how big the shake/wiggle is just highlight the 15 and pickwhip to the slider. That’s probably what you want.
The pickwhip is that middle symbol the look like a “@” under the now red expression controlled values.
Also, wiggling the camera’s Z rotation a bit can give it a nice (and queasy) feel.
-
Doug Nash
May 18, 2008 at 9:52 pmThanks SO much! I’ll dig into this, and see if I can understand the steps.
-
Nate Ledet
June 19, 2008 at 1:37 amI don’t understand why, but I get errors when I follow your instructions.
Maybe my set up is a bit different…
I have a camera and a null object. I have my camera attached to the null object, and I move the null object around. This allows me to move the camera so I can add the wiggle expression to the Position of the camera
Now, when I add another null object, we’ll call this Wiggle, I have this code in my Position expression:
w = wiggle(thisComp.layer(“Wiggle”).effect(“Slider Control”)(“Slider”),15);
[w[0],w[1], value[2]] ;the layer “Wiggle” DOES have the Slider Control on with Slider within it, but i get this error:
After Effects Warning: Bad Argument: Couldn’t find effect named ‘Slider Control’
~ Nate ~
-
Robin g Davids
June 3, 2010 at 7:01 pmI do it another way. Using the Null layer is useful if you’re applying the same wiggle to multiple clips, but if you’re just doing one or two, try this:
Apply the slider control to your clip.
Add the expression “wiggle(5,” to position. (without the quotation marks. Change 5 to what ever number you want. It refers to the number to times a second your video will shake)
Drag the position expression’s pick whip to the slider control. If you don’t know, the pick whip is the spiral below the position coordinates.
Then all you have to do is set your keyframes for the Slider Control and away you go.
-
Robin g Davids
June 4, 2010 at 2:26 pmForgot one thing.
After you drag the pick whip to the slider, you have to add another ) at the end of the expression. The final expression should be this:wiggle(5,effect(“Slider Control”)(“Slider”))
wiggle(10,effect("Slider Control")("Slider"))
Reply to this Discussion! Login or Sign Up