Tap into the FULL POWER of trim paths

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments

Will watch this in the office tomorrow and get back to you. Sounds good

👍︎︎ 1 👤︎︎ u/JonSonix 📅︎︎ Apr 06 2022 🗫︎ replies
Captions
what's up it's your boy cameron at xp and today we're talking about trim paths in after effects we're going to cover the basics of using trim paths but for those of you with a bit more time and ambition i'm also going to be sharing some secret tips to level up your trim path game and we're going to be creating some rad animations like these [Music] but for now let's just start with the basics we're inside of after effects and i've taken the liberty of creating a composition with these two objects in it a line in a circle so if i click on circle twirl this down come to add click on the arrow next to add and come up to trim pass and then twirl down trim paths i can play around with these two stopwatches you can see it kind of does what it says it trims the path it grows it on and it grows it off just using this one stop watch and uh if you want to see the difference between the end stopwatch and the start comes down to the directions so the start is the opposite direction to the end pretty much let's just reset this now if you actually want to animate this it's quite simple you can drop in a keyframe for your end drop in another one one second forward come back to the initial keyframe drop it to zero then if i come to one second and click on my start stopwatch go one second further and take that from zero all the way to a hundred i now have an animation where the stroke animates on and then it animates off and that's pretty much the basics of trim pass from there you can just kind of easy ease it play around with the timing to get some interesting things you can copy and paste with command or control c and ctrl v onto our line and you'll see exactly the same thing happens but really that's all there is to it from here this might be enough for you this might be everything you're looking for but if you're interested in taking it a little bit further i'm going to go into some tips and tricks that i've picked up along the way that you might find helpful for your own projects so let's get into that next so now we're getting into secret tips and this is secret tip number one animating a trim path from the center and set it from one side to the other and the way we're gonna animate this is by coming to our start and end top watches and i'm going to change these both to 50 and i'm going to drop in keyframes come one second forward and i'm going to take the end keyframe to 100 and the start back to zero and you'll see that animates in from the center and of course you can add some easy ease to make it a bit more interesting you could also copy and paste this and use it with a closed shape and that'll basically animate in a very similar way you could also come down to your offset if you wanted this to animate from a different part so if you wanted it to animate from the top let's say you could change your offset to 180 and that's what you'd get our next trim path tip relates to the offset function so i've already created an animation on our circle and i'm going to now play around with the offset to make something more interesting i can drop in a offset keyframe move it to the end drop in another one if i change this to something like negative 180 and let's add some easing to this you can see that we get a lot more movement in that animation now and of course you can change this figure to whatever you want however you need to make sure that it's animating in the direction of your end keyframes because if i give you the exact opposite kind of does what our previous example does however if you were to change the easing of one of these so i've just hit f9 to reset that or if i made this much more extreme you can see it it does some wobblies so i found it's best to stick to something that's moving in the direction of your previous animation for this next tip we're going to be having a look at trim multiple shapes right now we can switch between simultaneously and individually doing so when there's only one object inside of your shape layer isn't going to do anything so if i leave it on simultaneously but then come up and duplicate this shape internally just a couple times you can see when it's set to simultaneous they all animate on at the same time but change it to individual and they will animate on one after the other and this will be affected by the order whichever is at the top basically animates on first for this next tip i have a line that's animating on and animating off now what i want to talk about is a situation where instead of just a hard line you're having to animate on a dotted line so if i add a dash and a gap to this line let's make the dash 50 and the gap 60 when it's animating on from the end everything's fine but see what starts to happen when you start animating the start keyframes it starts to cascade and slide in this weird way and that's just not what you want so i've come up with a solve for this maybe you've come across a better one so if you have i would love to hear about in the comments so pop that in there but the solution that i've come up with is duplicating this dotted line changing it to line matte and we're going to basically remove the dashes from this line i'm going to thicken it up maybe five and i'm going to remove the trim path from that dotted line and i'm going to use the new line matte as an alpha matte for the dotted line and you can see by doing that it animates on and animates off perfectly the final tip is going to be using animation presets to save this animation and reuse it very easily so if you find that you're using trim paths a lot and you're doing a lot of animating them on and animating off you can save yourself a heck of a lot of time by turning that animation into an animation preset so the way that we do that is basically by customizing our animation however we want so i have this line animating on and animating off and i'm going to select all of these because i find myself using let's say 60 in 60 out easing a lot so i'm just going to drop in that easing and then i'm going to select these animation keyframes i'm going to come up to animation save animation preset and i'm going to call this from path effect and what you're going to want to do is make sure that you're saving this to the right folder so that you can access it later for me that's in users admin documents adobe adobe after effects user presets anyway i'm going to save this so now if i click on my circle twirl down my animation presets go to user presets i have my trim parts effect if i double click on that it automatically adds that animation right in with very little effort on my part and this is something you can do with a whole bunch of things animation presets can allow you to basically create custom effects for your shape layers or whatever and you can even stack them so if you had a bunch of things happening inside of your layer scale transform properties effects whatever you could select all of those create an animation preset and you could apply these things very easily to layers please drop a like and subscribe if you found this helpful so far now that that's out of the way let's get into the fun stuff we're all about real life application on this channel so instead of just learning a technique you learn how to apply it and use it creatively as well so when i was designing this tutorial i thought that instead of animating something new it would be interesting to deconstruct and replicate a really awesome existing animation that used trim paths or could be made with trim pass and i ended up with these [Music] these are two animations from a covert 19 project compiled by the furrow there are a whole bunch of designers and studios involved and many more to look at so i'll link to everything in the description but for now let's figure out how these bad boys were made so this is the first animation that we're going to reverse engineer using trim paths so what i did for this is i just created this very simple illustration and then i basically brought that into after effects and here you have that composition inside of after effects and of course i've already named all the layers so we can just dive into this i created a background layer which basically just animates on loop over these three seconds and now we can just dive into the animation part of it so for starters i'm going to click on line one in line two and because we've already created our trim path effect why not use that so i'm going to double click on our trim paths effect hit you to open up my keyframes i want everything to happen around about 12 keyframes so i'm just going to drag everything in and then i want these end keyframes of both animations to be linear keyframes if i hit control and click that'll change them to linear and all these initial keyframes i want to change to something strong like 80 and 80 ease okay the next thing i want to do is just offset that animation so they happen one after the other now we want to basically mimic that animation with our two dots on either end we want that to follow the path of these trim paths essentially so the way that we can do that is click on our lines come into our search panel and type in path and our paths show up so if i drop in a keyframe for both of those i hit x on this it'll close that up but i'll hit you again to open up those keyframes again now our first dot is outside of the screen here and that corresponds to line one so if i come over to this path and control c on that keyframe and come up to my dots and hit alt shift p that will drop position keyframes onto those two dot layers so if i click on my first dot and now hit control v that copies the animation from line one so because i used overlord to get these layers into after effects it sometimes does something funny with the position if you had made them natively inside of after effects you wouldn't have this problem but we have it here and i can show you how to fix that very easily so if i click on our first line layer you can see that this point here is where the animation needs to start so if i select our keyframes just drag this animation over and click control you can see it it wants to snap onto things so i can just come up to that corner and just drop that and you can see we'll have that animating in the right position and now all i need to do is match the easing drag this over there we have that animating perfectly with that trim power now we just need to do exactly the same thing for our second ball once again we're gonna have to find that snapping position so if i click on this here's the edge if i hold ctrl it will snap to that edge and of course the direction of this is affected by the direction that the line was drawn inside of illustrator and this was drawn in the wrong direction so i just need to come in here actually and uh time reverse these keyframes and change the easing to match and we have this animating on and the second one animating off now of course we don't want this to be here at this initial part of the animation so i'm just going to trim this in hold shift to snap it in the final thing we need to do is have this ball animate off with this line and we can just do that by copying and pasting this animation and you can see in the middle here because of these handles we're getting a funny bit of movement there many ways to fix this but uh what we're going to do this time is just hold ctrl alt and click on this keyframe and that turns it into a hold keyframe and essentially that stops that little wobble happening in between now we basically have exactly what we're looking for now we still have this final line to animate and i thought we could do this a little bit differently try a different technique and perhaps learn some new things along the way there as well so we basically have these two dots in this line and i'm going to use create nulls from past and this is a native plugin that comes with after effects and this can be very useful if you want to animate your path or have things follow your path whatever but today what we're going to use is this trace path function so in order to do that i need to twirl down my line three click on my path and hit trace path click on the path and hit u and my keyboard you can see it has this progress animation here and if you look here you can see the null actually follows that path which is exactly what we want for this because right now because we have that we can just come up to 3 over here we can just parent it to our trace line and you'll see now that just animates along that path perfectly now i'm just going to hide the line and the dots for now because i want to animate this in quite a specific way i wanted to have some nice strong easing so i'm going to come to about this point here drop in a keyframe i'm going to make this nice round 70 and i want to make this have quite a hard easing so it's going to animate in quickly and then suit right off so you can see what happens when i've done that it comes in quickly and then it animates off but what i don't want is it stopping at this point so i can select this keyframe click on my graph editor icon to open my graph editor and making sure that this point is selected i can double click on it and check continuous lockout going to incoming you'll see what that does in a second so if i hit ok i can now pull up this path so if i hadn't checked that i wouldn't be able to pull this up in one go it would kind of separate the keyframes now that we've done that i can pull that up and you can see what happens the movement is now continuous the ball is kind of animating in quick and animating all exactly how he wants that's fantastic now i can make this whole process even simpler by duplicating this line hitting you to open up my keyframes coming to the end and i can now show my dart 3 and parent it to our new trace line and it's going to be animating along that same path in the same way however we don't want them to be exactly in sync with each other so if i select this part of this animation and drag this back to somewhere around there 40 seems good you can see what happens now these animate on together and animate off in this very interesting way i'm loving that okay now we're not even going to do a traditional trim path on this because we have this information from these trace paths we can actually plug this information into a trim pass and i'll show you how to do that right now so let's bring on our line let's drop in a trim path if we look at this line here trace path trace line three we can see that goes from zero to seventy to a hundred again and that basically will correspond quite directly to what we want our trim path and to do so if i just hold down alt click on end to open up my expression box i can click on this icon here which opens up our pick whip and i can just pick with this progress i click out this updates in response to the progress that's just a really quick way to get the animation we're looking for and we can do the exact same thing with our start keyframes so if i hold alt and click grab the pick whip and come up to our second line for our second dot click out the start is being trimmed perfectly and look how great that looks is that not flipping magical comment below the word magical if you think that's magical okay so then the next thing that i would do at this point is basically duplicate these things a couple times you know bring bring this back just offset some of the animation just so we get a nice loop but just like a good old infomercial i've actually pre-baked this turkey and let me just show you that now so this is the pre-baked turkey this is what it looks like after i've repeated things a few times and basically added all the animation i want to so this is the second animation that we're gonna reverse engineer we're gonna focus on this part right here where it rotates and then match cuts into these squiggles that then come up and around and out this is the part that kind of follows so it's like matching there comes out then it pulls back in and then comes out again so what i've done is inside of illustrator i've made a suggestion of this path so this will be our starting circle and this of course is a suggestion of that middle part in the animation so if i come into after effects now you can see i've just set this up with that same moving background the gradients animating and i've just made this little bubble in the center just to give us something to work around and then i have the main circle and the main squiggle so for starters we're gonna look at the main circle so i'm just gonna solo that we're gonna start with some path animation so if i twirl down come into path drop in a keyframe there then i'm going to move to about 16 frames and drop another path a keyframe i'm just going to use my ruler to get an idea of where the path that's right now and you'll see why that's going to be helpful and if you don't have your routers active you just need to hit control r or command r and they'll pop up so there you go now if i select all of these half points double click i can now click on one of these handles or these uh points here and just hold ctrl see that just constrains it and this is why i was using those ruler lines so i can just match that up and make sure that i'm completing a full rotation here i'm just going to come in and ease this actually so i'm going to give this a really strong ease just a full 100 e so it really whips then i'm going to come to about 13 frames just when it's at this point i'm going to select everything and i'm just going to pull it in so it looks like a single stroke because that's pretty much what they have going on in the original at this perfect halfway point and i think it looks good aesthetically okay so i'm just going to come over to this keyframe hold ctrl and click and this creates what's called an auto bezier and this basically will just conserve the motion the speed between these few frames even if the easing here is very strong so that's the first part of this animation done the next thing we want to do is add some rotation so the way to get the right motion is making this minus 90 and having it go to zero so if i put on the right easing on that as strong as this path animation you'll see this is what we get and that's exactly what we're looking for okay so now that's pretty much done obviously it's unstyled but uh we'll get to the styling later so what i'm going to do is make sure this is cutting at this point because what's going to happen is that it's going to actually cut into the squiggle so we're going to change from one shape layer to another with a quick fast action so let's show this main squiggle and let's for now hide our main circle and let's animate this for starters we need to add a trim power so i'm going to drop that in i'm going to drop in a keyframe on the end and i'm basically going to bring this all the way down to something like 27 okay so that's where we're going to start and then we're going to move maybe 12 frames ahead drop another keyframe we're going to pull this around to about 56 we're also going to drop in a start keyframe and this is going to whip around to about 25 then i'm gonna move about 20 22 frames ahead and these are just going to both go to 100 and then once again i'm going to use some really strong easing on this i also want a bit of lengthening at this point what i'll do is i will pull this keyframe out a few frames drop an easy ease on it so it also whips out at this point one thing we don't want is the pause here just like some of the previous examples that's really not what we're going for we're looking for continuous fluid motion so if i grab these one at a time go pop into my graph editor we're doing the same trick as before click on the continuous check box and go back and do the same to the end keyframe now if we select both of these we can pull them up okay let's just get a feel for that maybe this can be lower yeah that feels good okay so already we can get a sense of that match cut so let's take a look at our two pieces together i like that i think it could maybe come back one frame yeah i think that actually works a lot better now the one thing we want to do to this is getting that tapered stroke feel to it that we have in our reference so in order to do that we can actually just use the built-in shape layer functionality so if we twirl down group one pull down stroke fold down taper we can add a start length and a start width i also want to change the stroke width so we're gonna do that as well and then i'm gonna just drop-in keyframes for these at this point here so for starters our start length has to kind of happen quite quick i'm looking for kind of quick snap to something quite dramatic you know so we get the taper quite quickly i don't want this to be a perfect sharp edge i'm going to start this with off that 50 and take it up to i think i'm taking it down actually yeah so that that's where i want it i actually wanted to start off thicker and slowly come to a sharper point that looks good and you know i'll ease that in the same way it's always a good idea to match your easing it can really make things feel much more cohesive and that's definitely a pro when animating i'm just going to take this up to about 280 at this point so we really get a nice thick stroke once again strong easing i pull this out a bit i'm gonna take this back down to 150 at this point so it thickens up a bit and then it thins out and that's pretty much it all we need to do is now make sure there are two of them if i duplicate this i'm going to pop in a null because this goes right to the center i can just parent the main swiggle to the null and i can open the rotation on the null and just to 180 and i can pretty much delete them all so i'm just going to show up everything and there you have it all we used was trim paths to create this and it has a really cool feel to it we have this nice match cut happening and these nice little squiggles popping out so now we're going on to the styling and this is a really great opportunity to get familiar with a technique that uses layer styles so if you click on shape layers and you right click and have a look at layer styles you can see there are a bunch of options you can use here and these are actually a great way to customize your layers and they aren't often used okay so for status we're going to drop in an inner shadow and i already have the right color and i copied here so i'll just paste that in and i'm going to change this to normal 100 opacity and you can see it's added this little line there now if i come up to the distance and increase that to about 45 increase the size something like 35 and i'm going to change this to 45 that's what i'm looking for in a shadow right now so the next thing we're going to do is add a highlight and the way we can do that is using a bevel and emboss so i'm going to come in leave my shadow opacity or take it back down to zero keep my highlight on screen and 75 percent and i'm just going to increase the size to something like 160 and change the angle for something that's opposite the shadow so around negative 160 we're getting a nice 3d effect already next thing i want to do is drop in a inner glow [Music] pull that down i want to change the color to something and quite quite pinky yeah something around there like a kind of strange magenta and this is on screen already so it adds this uh this kind of color to the edge there so if i increase the size to about 80 but then reduce the range a bit it's not like 20. yeah i think that's a bit too big i'm going to drop that to about 40. now you can see it just adds a little bit of extra readiness to this object okay the final thing that is going to finish this off is adding a glow i'm going to drop in a glow into that main circle and i'm going to make sure that it's on top but it's only in these areas and i'm going to make it slightly bigger the radius of 20. and that's exactly what we're looking for and the great thing about layer styles is i can now just ctrl c copy all of them and just paste them with ctrl v directly onto my squiggles and i have them matching those exact styles okay so once again i pre-baked all the refinements to this we can have a look at that right here i'm not going to go over everything here because the trim paths are the main point but if you want to jump into the project files that are linked below you can do so and you can ready decode all of this stuff and see exactly what i've done to achieve this effect so yeah thanks for watching project files are linked below so be sure to check that out i hope you've gained something valuable today and if you have why not subscribe so you can keep gaining xp and leveling up your motion design game [Music] [Music]
Info
Channel: MotionXP
Views: 62,748
Rating: undefined out of 5
Keywords: trim paths, trim paths after effects, trim paths tutorial, motion graphics tutorial, after effects tutorial, trim paths animaton after effects, trim paths animaton, motion design tutorials after effects
Id: G_f2Brb1L_E
Channel Id: undefined
Length: 29min 26sec (1766 seconds)
Published: Tue Mar 08 2022
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.