Copy link to clipboard
Copied
Hello,
I am writing an expression that will scale in and out an object based on slider controls. The problem I have run into is trying to create a "pinch" graph effect, where the arch of the easing effect becomes tall and thin.
Thanks!
The expression bit throws me, but this ease expression will allow you to "range map" from the sliders to your scales:
var easedScale = ease(effect("Slider Control")("Slider"),0,100,25,75);
[easedScale,easedScale]
the 0,100 represents the minimum and maximum values in the slider and the 25,75 sets the min and max scale values.
The speed graph can help with creating a pinch, but it does sound like you want to control this through the expression and I take it you can't apply the speed graph to th
...Copy link to clipboard
Copied
The expression bit throws me, but this ease expression will allow you to "range map" from the sliders to your scales:
var easedScale = ease(effect("Slider Control")("Slider"),0,100,25,75);
[easedScale,easedScale]
the 0,100 represents the minimum and maximum values in the slider and the 25,75 sets the min and max scale values.
The speed graph can help with creating a pinch, but it does sound like you want to control this through the expression and I take it you can't apply the speed graph to the slider keyframes. If so, it sounds like you need an IF statement, so that:
If (slider < 50) {
ease up
} else {
// when slider is beyond 50
ease out
}
Without seeing what you have so far, that's the best I can do.
It is really easy to get lost in the weeds when it comes to expressions and you end up spending more time than you should just trying to program something. One alternative to consider is to use Pre-Comps with Responsive Design - Time enabled. This lets you use keyframes to get the perfect animations, but then you can extend them, have them pause and all sorts and you never need to go near an expression.
Copy link to clipboard
Copied
I had no idea Responsive Design was a thing. This is exactly what I am looking for. Thank you for your help!
Copy link to clipboard
Copied
It turned up without fanfare a few versions back, about the same time as Essential Graphics. Whoever was naming things in Adobe at the time didn't really nail the obvious titles concept.* I ignored both for ages, but once I tried them, I discovered just how much of a time saver they both are.
* And yes, I've no idea what I'd name either. Maybe "flexible precomps with fixed bits" and "reusable precomps you can change the stuff in". Maybe not.
Copy link to clipboard
Copied
You're probably going to need to mess with valueAtTime() or a custom easing formula alltogether. Impossible to tell without more info.
Mylenium
Find more inspiration, events, and resources on the new Adobe Community
Explore Now