Answer the question
In order to leave comments, you need to log in
How to automate animation?
How to automate the capture of text by a shape? Now I did it manually, through position for each layer
Answer the question
In order to leave comments, you need to log in
I know that it's been two months, but I stumbled upon it by accident and decided to answer.
Actually, create layers with shape and text. For a shape, use keyframes to set the start and end position ( Position method ; "hot key" P ). Enter the following expression in the Position
method of the text layer:
x = transform.position[0];
y = transform.position[1];
shape_y = thisComp.layer("Shape Layer 1").transform.position[1];
if ( shape_y > y ) {
[x,y];
} else {
[x,shape_y];
}
margin = 14;
text_width = thisComp.layer("Sample").sourceRectAtTime().width;
text_height = thisComp.layer("Sample").sourceRectAtTime().height;
box_width = text_width + margin*4;
box_height = text_height + margin*2;
[box_width, box_height]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question