Forums › Adobe After Effects › Cam and follower-object rotation causes linear movement.
-
Cam and follower-object rotation causes linear movement.
-
John Cuevas
May 27, 2022 at 2:00 pmNeed to recreate low resolution videos and having a brain block on doing this in an automated way(I have to do it for multiple shapes). Is there a way to create this procedurally, with expressions and parenting.
-
Filip Vandueren
May 29, 2022 at 10:09 amHi John,
maybe this project of mine from a while ago (I can’t find the original question here on the cow) can help, I don’t have the time right now to go deeper into it:
The original question was about squeezing a ball into a cavern, and I remember I made some mehtod that “felt” the distance to the walls by trial and error / refining over a few iterating guesses untill the radius comformed.
-
Walter Soyka
May 29, 2022 at 11:53 pmHere’s a sample project.
It has three components: a layer we need to find the top of, a null that will represent the top of that shape, and the graphic elements we parent to the null.
You have to initially position the null inside the target shape; then an expression on the Y position uses a binary search to somewhat-efficiently sample the comp raster column above the null image until it zeroes in on the transition point between transparent and non-transparent alpha (aka, the top edge of the shape).
Here’s a little GIF of the results in action, too, on a couple different shapes.
-
John Cuevas
May 31, 2022 at 3:02 pmThank you Walter and Flip. I brute forced the first one, but Walter, what you have done is going to save me a bunch of time on screen where I need to show 6 different cam shapes. I was in way over my head on the expressions for this project.
-
Walter Soyka
May 31, 2022 at 7:32 pmYou’re welcome, John! Let me know if you have any questions on how it works; I’d be happy to explain in more depth.
Log in to reply.