After Effects Tutorial - Dynamic Text Box

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
they said it couldn't be done they said I was crazy but I've done it a dynamic text box with minimal expressions and minimal effects that dynamically updates as you change your text without the need for - space - Fox without the need for shape layers masks or anything because it's all on one layer let's peek behind the curtain and see how we create this in Adobe After Effects [Music] so here in a brand-new After Effects composition and what we'll do is create our text layer we'll go select our text tool or you can hit ctrl T and we'll click in the middle and type it our text now now we're going to add in a bunch of expression controls just to give us a bit more control over how things look at the end so we'll go to effect expression controls and slider control and this is just like basic value so we'll rename this to additional left and then hitting control D we can't actually duplicate the selected effect so in this case we're going to call this new one additional right and we'll hit control D again hit enter and we'll call this expand edge now we need one more expression control and that is our color control and this is going to be our box color so now we have our expression controls we need now we need to add the actual effects that'll drive our dynamic text box so we'll go to effect stylize CC reptile and what CC reptile will do is actually it determines the spacing between our edge of our text and the edge of our box so this does although the cool stuff like that so you'll see we have four different properties but I don't want to have to write four different expressions trying to calculate things I just want to run it on the one I'm gonna hold alt and click on the stopwatch on expand right and then I'm just going to pick with it to the expand up property so I'll write my expression um expand up but for these I also have the additional left and additional right that gives me a little bit more control over the customization at the end so I'm gonna hit + and actually pick whip this to the additional right slider as well now I'll do the same thing for we expand left only I'm selecting the additional left slider now expand down is the simplest of all I'm literally just gonna refer it to expand up property semicolon and click off it and you can see there we go that's what we need for those now if we expand up I'm going to click on and type my equation now because the scaling of my text layer doesn't naturally translate into the value for our reptile properties I'm gonna need to do a little bit of maths here additionally I'm gonna need to know if I'm actually scaling with a parent null or not as that tends to be the way you control groups of layers so I'm just going to use the try expression to be able to determine if I'm using a parent or not so in this case I've worked out that 0.15 times the parent transform scale 0 minus 3 gives us a pretty good result now scale 0 is purely referring to the fact that we scale in both the X and y dimension but naturally we're scaling both of them together so it doesn't really matter which one of these it refers to but I need to pick one of them now I'm also going to hit plus and pick whip our expand edge and that just gives us a little bit more control as well and I'm going to select this whole thing that I have here because I want to do the same thing if we don't have a parent so in that case I need to type catch error and then have our function like so and I'll paste it and just remove the parent being referred to there and everything else is pretty well the same so you can see if I try to do this with a parent it's going to actually give me an error because there's no parent for this actual layer but it will actually refer back to alright what to do when I have that error in this case it's just going to do the normal transform and refer to a transform of our text layer that's completed now and you can see clicking off we start getting this interesting sort of border around now we need to add our next effect which is if I select the layer effect generate beam and I'm gonna drag that to be just underneath our reptile layer here now we're getting change a bunch of these effects we want a length to be 100 the time it doesn't really matter I'm gonna say our starting thickness is 1080 and our ending thickness is 1080 and we'll drop the softness to 0 now for the inside and outside color I'm actually going to hold alt and click on that and actually pick whip all the way up to our box color because I want it to be driven off that box color and if I go in here I can pick any kind of color I want there's our good old media workbench gold that we have now additionally I'm gonna want to put a quick expression on our starting point in our endpoint and this really isn't calculating all that much it's just kind of forcing it to have a variable so we're gonna do square bracket 0 comma this comp dot height / - and we'll click off and for our endpoint we'll square bracket this comp dot width comma and this comp dot height / - square bracket and what these two values are doing is it's forcing the beam starting point and end point to be in the very middle horizontally for our composition but also be on the far left and far right so basically filling up the entire space you'll see though that it's not actually visible in the entire space it's purely within where our text layer area is and this is the sort of cheeky tricks that makes this whole thing work our reptile layer is actually pushing out our boundaries for our text layer and then our beam is actually just generating within those bounds we need one more expression in order to bring our text back and that is under effect channel CC composite and we'll drag it up like so and we'll change our composite original over to silhouette alpha and you can see there now our text is kind of clearing through we can see things nice like that if you want you can also do this to being in front and you can just pick color that you want that works well you've got a couple of different flexibilities in that now if we hit S on our actual text layer and scale it up and down you'll see that the edges actually scale nice and in proportion additionally if we actually show what these expression controls let us do the additional left slider if we drag it to the left actually expands out so we've got some cool stuff going on there if we hit control Z and do the same with the right we can do the same thing there so you can see how it can easily give you a bit more flexibility in how you present things additionally the expand edge gives us the option of expanding and then you can see as we scale up and down that's kind of kept in proportion like so and you could parent this to a null object we'll create a quick one like so pick with the parent of a null and scale the null and you'll see things stay in proportion like so and this would work for any font that you want say if you went for impact there you go you can see like so and we can easily go in and change this to say anything and additionally it works quite well as multiple lines if we just give us a space there you can see how it turns into that result like so so that's of a dynamic text box you can see it has a lot of different controls to it a lot of potential in your compositions a quick thing of note though is that this isn't completely foolproof if I try to rotate it you can see the Box kind of just it doesn't rotate it just does weird stuff so in this instance you'd have to pre compose this in order to get that same effect additionally you may find that the text disappears while you're working in it in your composition and that just has to do with a way it's trying to render stuff if you go edit purge all memory right before you render it generally doesn't have any issues to speak of but if you're trying to layer it with multiple effects on top it can be a little finicky I find the best thing to do is kind of pre compose it if you're going to be doing anything like that but for general use and you'll see this used throughout all my media workbench videos it works fine so that's how you create a dynamic text box you can animate the text as you would in a bunch of different ways and you can get that effect really working well if you have any ideas of how to use this or potentially solve some of the issues that it presents then leave a comment in the comment section below until next time my name is mentioned thanks for watching [Music]
Info
Channel: MediaWorkbench
Views: 57,652
Rating: undefined out of 5
Keywords: adobe, after effects, photoshop, tutorial, media, workbench, media workbench, bench, michael, auto-resize, resizing, dynamic, text box, dynamic text box, box, text, self resizing, auto resize, lower third, dynamic lower third, transparent text block, transparent, text block, scale, size, lower 3rd, lower, automatically, automatic, monospaced, font
Id: Sf7ezaDcfcQ
Channel Id: undefined
Length: 10min 0sec (600 seconds)
Published: Wed Sep 26 2018
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.