Forums › Adobe After Effects Expressions › After effects Expressions – Increase Stroke Effect/Brush size with null
After effects Expressions – Increase Stroke Effect/Brush size with null
Tomas Bumbulevičius updated 1 year, 2 months ago 2 Members · 2 Posts
Jason Nizzetto
November 11, 2019 at 2:43 pmHi all, this is my first question, hope you can help me with this and thank you in advance.
I’m doing an animation where I have some text (shape layers) that appear with a write-on reveal effect. To create this I imported the expanded text from Ai, created shapes from layers in Ae and applied a Stroke Effect (with paint style set to Reveal Original Image) to each separate layer (each letter); I then keyframed the End parameter of the effect so that the text appears.
The whole thing is pre-comped and part of another composition with a fly-through camera.
My issue started when this text pre-comp was losing sharpness due to the pre-comp being too small, so I resized pre-comp dimensions, created a null, linked each text layer to the null and increased this. By doing this, the Brush size of the Stroke Effect remains the same and the text gets all messed up.
I tried to create a slider for the null and pick whip the brush size to the slider, but that doesn’t work.
My idea for making it work is to have the Brush Size increase by the same percentage value as the null’s scale property, but I have no clue on how to do that.
I apologize if this explanation is confusing and I’ll provide any other details if missing
Thank you very much
Tomas Bumbulevičius
November 13, 2019 at 10:56 amHey Jason, assuming transformations are proportional, try to apply this to stoke:
nullScale = thisComp.layer("null").transform.scale[0];
textScale = thisComp.layer("text").transform.scale[0];
brushSize = 10; //Your default value for brushbrushSize * nullScale/textScale
Find out more:
After Effects Tutorials: motion design, expressions, scripting.
Boxer – Dynamic Text Boxes Template with a Live Preview
Log in to reply.