Skip to main content
JakobSjobom14249257
Known Participant
May 17, 2017
Answered

Row of text animation (y position gap for underlying layers) expression

  • May 17, 2017
  • 3 replies
  • 3707 views

Hi guys

So I´m creating cooking videos and want to present ingredients through animation (simple position x animation). Each ingredient on its own row. Animation of each row to start slightly after the previous one.

The animation will be saved as an Essential Graphics animation in my library for reuse in PP. The number of ingredients will vary of course. And, the gap between the rows could vary depending on the total amount of ingredients on each recipe and the font size chosen for each recipe.

That´s the background sort of. Anyone with an expression tip on foremost the y positioning?

Thanks!

This topic has been closed for replies.
Correct answer ericsten

Hey Jakob, yes that whole expression goes in the position of each text layer.

Please note that this is set up to have your layers arranged with your text layers grouped together top down, with your control layer "Null" just above. This gives them their order in the group and the null tells your first text layer that it is the first in the bullet list.

Make sure you add the sliders and name them as I had specified in my first post.

- Eric

3 replies

ericsten
Inspiring
May 18, 2017

Hey Jakob, based on your description you may want something like this.

Create a Null Object and name it "Control", place it right above your list of text layers.

Add two sliders, name one "Group Y" and the other "Spread"

A=thisLayer.transform.position;                                                               // This layer's base position //

try {B=thisComp.layer(index-1).position;} catch (err) {}                           // Try to assign layer above's position to B variable //

try {C=thisComp.layer(index-1).text.sourceText;} catch (err) {C=false}  // Check to see if layer above is a text layer //

GroupY=thisComp.layer("Control").effect("Group Y")("Slider");             // Get value of "Group Y" Slider //

Spread=thisComp.layer("Control").effect("Spread")("Slider");               // Get value of "Spread" Slider //

if (C!=false) [A[0], B[1]+Spread] else [A[0], GroupY]                               // If the layer above is a text layer, spread, if not reference group Y//

JakobSjobom14249257
Known Participant
May 20, 2017

Hi ericsten

Thanks a lot for this! I sure will look in to this! I'll update here with how it goes. I just have to attend to another project that sudddenly got assigned to me, first.

jakob

Dave_LaRonde
Inspiring
May 17, 2017

I agree with Mylenium. It would appear you've chosen a workflow based more on Adobe marketing propaganda than on knowledge of what will work best for you.

JakobSjobom14249257
Known Participant
May 17, 2017

Hi Dave

Same thought after my response to Mylenium?

Let me describe the thought out workflow.

- I would create ten rows of dummy ingredients as a template

- After creation of the template in AE I'd import it in my library as an essential graphic

- in PP I would use as many rows that I would need, let's say three, and leave the rest blank.

For recipe X:

- 3 ingredients. Very few, why the text size can be quite big. But the row gap would have to adjust according to size (or rather, the distance from the row/layer above)

- Leave the rest of the seven rows blank.

For recipe Y:

- 7 ingredients. A bit mire of them this time. The font size cant be as big as the last example but the gap would have to be good and coherent.

- leave the rest blank.

Again, maybe I'm overthinking this. Or? :-)

Dave_LaRonde
Inspiring
May 17, 2017

I think you need to think about the total audio-video presentation, that's what I think.  It doesn't sound like you have a firm grasp yet on how you're going to pull it off.

Just for the heck of it, here's an ingredient list for Beef Braggiole, something I plan to make soon just 'cause I like it:

  1. Beef
  2. Home-made bread crumbs
  3. Eggs
  4. Onion
  5. Garlic
  6. Parsley
  7. Salt
  8. Pepper
  9. Red cooking wine
  10. Salt pork
  11. Grated Romano
  12. Basil
  13. Oregano

That's thirteen ingredients, just off the top of my head.  I forgot to list the Pancetta.  Now, that's just for the Braggiole.  Not to mention the Marinara sauce.  No quantities listed.  No ancillary items like butcher's twine listed.  AND NO TECHNIQUES DESCRIBED.

What's happening on the audio?   Do you plan to do it all-voiceover?  Do you plan to have an on-camera presenter showing the proper techniques?  Do you intend to give the viewer time to write down the ingredient list and take notes on technique?  Do you plan to add supplemental graphics such as, "Finely Chop 4 Sprigs Italian Parsley" as the chopping takes place on screen?

Or is this just an ingredient list so far?

If you ask me, I think you need a more comprehensive plan before you start worrying about using expressions in After Effects.

Mylenium
Legend
May 17, 2017

Why expressions? That makes totally no sense. You would simply apply text animators or put the stuff in a pre-comp for easy editing or both or a million otehr techniques involving effects such as transform and Motion Tile. It might be worth rethinking your approach rather than on looking for solutions that likely won't work in Premiere, anyway. You can't even change the font, so pardon me, but it seems you haven't thought this through correctly.

Mylenium

JakobSjobom14249257
Known Participant
May 17, 2017

Hi and thanks for your response!

For the animation itself there's no need for expressions. But I would think that for the y positioning of each row, an expression would be appropriat, to control the gaps between rows to accommodate for various font sizes. And maybe to to control the start of each row animation.

And regarding font; i will use the same font every time.

Maybe be you're right of course, I'm a bit of a noob in AE. But to avoid to manually change text size and row gap for each layer - that's why I thought expressions was the way to go. Are you with me? :-)