Stepan Dorodnykh's profile

Expressions torture

I tortured myself with expressions
If you have any questions about any part of this video, feel free to DM me on Instagram @annimier777

This project was my convoluted way of learning expressions in After Effects once and for all. I kind of know C, so it wasn't difficult due to my background, but I just had to go through that process the hard way, so I set up a challenge for myself: I must not use any effects for anything other than color, I must animate by hand only one object in the scene, all the other objects have to be animated through expressions with dependencies on the main object. And the most important part: I can only use adobe expression language reference guide and wikipedia to remember trigonometry. No googling of similar-looking things and copying!
Repulsion and attraction
The idea was to create a circle around the main object that would repel everything out to the fixed radius, while also creating an attractor that would suck everything towards the main object. So the stronger the attraction is and the longer the radius is, the more squares get stuck on the "event horizon".

The ultimate challenge for me was figuring out the correct way to displace the squares. In the end I used vector maths to accomplish that. Basically I was "sliding" the squares in the direction of the vectors that are created by connecting the main object and the squares.
Waves
In this shot I used the dreaded SampleImage method. I created the wave matte out of circular shapes, which adaptively reflect from the composition borders. Then I used the SampleImage method on each hexagon which scans the pixels of the wave matte layer for luminocity. If the luminocity is greater than 0 the hexagon isometrically moves towards the upper left corner of the composition and gains opacity. This effect's strength is linearly dependent on the matte's luminocity.

By the way, the SampleImage method is dreaded, because it destroys your performance. Do not use it.
Flocking
This shot is pure trigonometry. I populated the field of view with these rectangles by using some equivalence of sqrt(x) function for xPosition and expanded them in Z space. Each rectangle is slightly rotated upon creation using random(), and all of them rotate towards the main object with reverse square force to distance ratio.

It was difficult for me to make them appear from below the camera FOV in a slight wave, and reviewing the code now, I don't think I have enough time to comprehend it.
Expressions torture
Published: