-
Parent animation timing to markers
When I ask this question via google, I often get some variation of the expression below.
This is a nice code and all but not what I’m looking for. I want something more like what the mister horse animation composer does with it’s animation presets
Being able to adjust the timing with markers. not just where something begins but the duration of the animation as well. not using sliders but using markers. If anyone knows how to do this I’d be very grateful.Example of what I mean by the mister horse presets. in this video at 1:20
https://youtu.be/PywvZOy-OaQ?t=72// Keyframe your animation, starting on frame 0
// This property will animate at every marker on this layer// If the property has no keyframes, the value at frame 0 is output
if (thisProperty.numKeys == 0) { t = 0; }// Find the previous marker from current time
else {
n = 0;
if (marker.numKeys > 0){
n = marker.nearestKey(time).index;
if (marker.key(n).time > time){ n--;}
}// If there is no previous marker, the value at frame 0 is output
if (n == 0){ t = 0; }// Calculate t from elapsed time since the last keyframe
else{
m = marker.key(n);
t = time - m.time;
}
}
valueAtTime(t)Some contents or functionalities here are not available due to your cookie preferences!This happens because the functionality/content marked as “Google Youtube” uses cookies that you choosed to keep disabled. In order to view this content or use this functionality, please enable cookies: click here to open your cookie preferences.
Sorry, there were no replies found.