Set up variables in After Effects:
Create a variable by adding the control to your layer:  Effects > Expression Controls > Slider Control
Name it "Wiggle Strength"

Add the Wiggle code to the property to control:
In my case, I'm adding this code to the Orientation of a 3D layer. I want to start out with a close-up camera on the object, where having it Wiggle doesn't look good. Once the camera pushes away from the object, I want it to drift ever so slightly in its Orientation (rotation).

// --- Wiggle with Keyframable Strength ---
var freq = .3; // Sets the wiggles per second.
var strength = 0; // Default strength; gets its value from the slider below.

// Links 'strength' to the slider; defaults to 0 on error to prevent breaking.
try {  
  strength = effect("Wiggle Strength")("Slider");
   } catch (e) {}

// Adds wiggle on top of existing keyframes/values.
value + wiggle(freq, strength);

Ready to start?
My proven process transforms complex innovations into compelling visual stories that connect with your audience. From concept to final delivery, let's make your breakthrough communication a success. Call or send an email today.
Start Now