Cinema 4D Tutorial - Intro to Mechanical IK Rigging

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey everybody it's EJ from I design comm and today we're going to get a little intro into mechanical eye caring and how you can introduce it into your workflow let's learn how all right so this is what we're going to be creating today we're going to be animating today along our journey of learning mechanical eye k rigging so we just have this nice little spring board set up where the squash is down these nice little joints and everything rotates super nicely and let me tell you this is just a super easy setup and mechanical like a is something that if you've learned no ika tall this is the type you should definitely learn so the first thing I want to cover is the two types of rigging there is forward kinematics SK or inverse kinematics I K and basically inverse kinematics is the inverse of forward kinematics and in forward kinematics is the easiest and the simplest to set up but it's also the most laborious way to animate a character or a rig and basically this setup is how you would set up any type of object hierarchy whether you're in After Effects or anything else where if you want an object or a group of objects to rotate along the center axis of another object you would just make all of those objects a child of that main object so I just made the upper arm which is just we have just a simple robot arm or hinge hierarchy here made up with just some cylinders and some cubes and we have our shoulder and if we rotate the shoulder you can see it's going to rotate everything underneath it that is the basic premise of forward kinematics with a topmost object if you animate it it animates everything forward along down the hierarchy chain so if we want to be able to rotate some objects like the forearm and the hand using the elbow we would just need to place the forearm in hand as a the elbow and now we can rotate those objects by rotating that elbow cylinder so then we can also rotate everything again and if you want to animate say this hinge or this robot arm waving you would need to animate both the shoulder and the elbow and again this is very laborious super manual process of animating it's very inefficient because you have to animate two objects and sometimes even more if this joint chain was even longer that would be a super long manual process of animating this whole entire rig the benefit of the inverse kinematics is that it actually works inverse and you only have to animate one object this hand to move everything up the chain so inversely so instead of having to animate shoulder on down you just animate one object and it animates everything above it or moves everything above it so let's just show this in practice so we have for our for our eye case setup the same hierarchy as the FK so we can even check that out and you can see you got the same setup but the thing we're going to do is inverse kinematics is a more automatic process in the problem with automatic processes is that sometimes it doesn't automate the right way and for inverse kinematics if you have a rig like this and you want this elbow joint to always face downwards you need to tell the inverse kinematics give it a little bit of a hint before you apply inverse kinematics to this rig which direction you want that elbow joint to point towards and how I do that is usually by just giving a slight rotation to the rig so you can see that it's slightly angled downwards so you can see our shoulder rig move down and this this little elbow is facing downwards now so we got a slight angle so now when we actually apply inverse kinematics it's going to bend like this and not like this or sideways or whatever so just doing a little bit of work before you apply inverse kinematics or ik2 this saves you a lot of tweaking in the long run because if you don't set that up and everything's flat it's come it's going to take its best guess at which direction you want that elbow joints point towards and typically it's wrong so just we're just giving it a hint we want to point downwards and let's actually see what that actually means so to set up an IKE a rig we just have to select the first object in our joint chain that we want to rotate around and one thing I want to point out is that I actually have these cylinders as our pivot points so sometimes you don't always have these pivot points sometimes you just have objects right so what if we didn't have this shoulder here well let's just delete the shoulder choose this upper arm we would need to change our hierarchy here because when we move this upper arm we actually want to move everything underneath it so we need to make the elbow a child of the upper arm and now I can rotate and you're going to notice that our axis Center is actually the center of our cube and typically want to have the pivot point up here towards where the shoulder would be so to do that we're just going to make this rectangle editable by hitting C and now we can actually change the axis Center here by going to our axis modification mode and then we can just slide this axis to the left and now that will be our rotation axis so just very important you know because this specific setup actually has shoulders and stuff like that that you can actually rotate and pivot around but if you don't you just can manually position the axis Center wherever you need it to be so it's rotating along around that correct pivot point so keep that in mind let's go back to our rig here and for the inverse can max to work you would need to select the first object in your hierarchy and then the last object in your hierarchy which will be this hand and we're just going to go to character commands create eye-catching and that's going to do two things number one it's going to apply a Nike tag to your topmost object and it's going to automatically place that bottommost object our hand and list it at the and define it as the end of this whole joint setup and it's also going to create a goal and basically the goal is just going to help position or its kind of position where that hand goes now watch where watch what happens now now I'm moving my goal and that's actually moving the hand and it's bending my arm downwards because remember I had this facing downwards a little bit now we could also go into rik chain and change our pole vector and basically the pole vector is the direction in which our elbow joint faces so if we want this to face upwards we can just twist this 180 degrees now you can see that our elbow will Bend upwards but we'll just leave that at zero and we can also create a pole as well and we can actually use a null to position where that is facing but we'll just undo that so that's just a little bit about poles there and if you want to know more about poles and all that good stuff and more into I K definitely check out my character rigging tutorial which I will link in this video right above hopefully and let's just go back in again our goal is controlling everything so you can see how this is completely different or backwards from our forward kinematic rig where our shoulder control at everything in our I care it our hand or a goal actually controls everything and see how much easier this is to animate a rig because you only need to animate one object versus two or even more in forward kinematics so hopefully that gives you a little bit of an intro to how inverse kinematics work and even if I turn off my form in my upper arms visibility you can see this green line that just shows the connection between that shoulder in our upper arm or our hand here so you can see how this works so let's apply this to our main setup here so our springboard here so you can see that we have the same kind of setup we have these nice little hinges these cylinders and then instead of cubes we just have some more fleshed-out modeled pieces here and basically this is just an extrude object of extruded rounded rectangle and then the sweep is just a swept circle along that same rounded rectangle and again same set up these are just replacing the cubes and we have our hinges as cylinders so we can if we want some if we need some little helpers this could be our shoulder so we can just name these to help us better understand what all this stuff is and this is the elbow from before our sweep object is our forearm and our top hinge this is our basically our hand and because this is going to be grounded at the bottom here this is going to be our shoulder and this is going to be our hand here's our upper arm and then basically we just have to set this up the same exact way that we did before and one nice thing to do is to be able to just order this in the correct hierarchy so our shoulder and then our upper arm will go next then our elbow then our forearm then our hand so now we can just go and say all right we need the upper arm in the elbow to be a child of that shoulder and again we can do a little bit of forward kinematics test to make sure everything is connecting the right way so that's good and then we need our forearm in our hand to be a child of that elbow so now again we can use a little forward kinematics rotation to test that out and cool everything's work in that way and then everything is controlled by that shoulder cool so now what we'll do is we need to make sure this top disc is actually connected to this ring somehow so we'll just place the top disc as a child of that hand and now that is part of our rig as a child of that hand so now we're going to do the same thing as we did before and select the first object in our hierarchy which is our shoulder for that first hinge and then that lap hinge or hand we don't want to select the top disc because that's not actually part of our rig it's just going to be connected and following that top hand hinge here and we'll go into our character tag or a character menu create eye-catching and again the same thing is going to place that eye Kate tag here and we're going to have our goal and you're going to see that I can move this goal and we have the same kind of setup that we had before before I get too far in here though and once you undo that and one thing that's what you want there's one thing you want to do when working with goals and stuff like that because we have our starting position here already if we make too many changes we could lose that starting position we could get into a very messy situation with a rig being out of place or something like that so typically what I like to do is store the original position and you can see that the only thing that is changed as the Y and we're going to freeze it and it's going to store it down in this freeze transformation area and what this frees up is it makes all of our original coordinates start at zero so what we can do is we can move this all over the place you can see all crap our rig is screwed up let's hurry up and get back to our original position we can either manually zero out these these position coordinates or if it's really screwed up we can just go and hit this PS r0 button so reset PS r and I have this actually docked in my setup here in my UI because I use it so much if you don't have a docked I recommend you docket especially with character work but if you don't have a dock and you want to pull it up really quickly all you have to do is hit shift C to bring up commander I believe commander was added in cinema 4d R 16 but it's super handy you basically type in any command and we just need reset PS or arnelle show up and then we'll just click on that double click on that and that'll then reset the PSR of our gold perfect alright so one other thing I want to do is be able to control this and grab our goal without actually having go into our object manager and the way we can do that is by changing our display from a dot where you can't actually see our null and we'll just change this to a circle and you see a circle representing our null and then we can just scale this up and now if I want to grab that goal and move it I just click on that circle and now I can control this without actually having to go into my object manager again reset PSR cool alright so now we have one problem and that is we actually want this spring to spring upwards and you can see that our top disc is moving and rotating and the reason for that is is that our hand is actually rotating as well it's trying to rotate back to this original connection line so what we need to do is constrain it so this y-axis is always facing straight up straight up in positive Y so to do that we'll just go and actually Bentley hit reset PSR on the hand so I'll just undo that watch out for that and I'll hit reset PSR on the goal there we go and for this to be constrained this hand cylinder to always be constrained to looking upwards and having the y-axis always facing upwards we're going to use a constraint tag now you can find any character tags constraint and you can see that this has a bunch of options and I consider it almost like the Swiss Army knife of character animation because it does so many things the thing we're going to use this constraint tag for is to tell it to always face in a positive Y so we always want it facing up and that is actually considered our up vector so the direction we want it to face is the up vector in our up Vector you can see by default is already set at that positive Y so if we did this correctly and we move this around you can see that no matter where we move this our hinge our hand hinge is always going to face in the positive Y which is exactly what we want cool so we'll reset PSR and with that setup we can now recreate that other part of our hinge over here and to do that we're just going to simply duplicate this whole entire rig and then we're just going to rotate this 180 degrees and you're going to see that we actually have duplicates of a lot of things we actually don't need one being this top disc we already have that in our main hierarchy so this will be just our left shoulder setup and you can see I can change this I kate AG or actually I don't need to change this I Kate tag at all because it's already set up to have this hinge hand as the end and it's also using our first are the only goal one are seen as the goal for this rig as well and the only thing we really need to do is just hide the visibility of these redundant hinges because we already have the hinged shoulder and we already have the hand shoulder we just have them in the same place and basically these are just placeholders telling this this set up this rig where all the pivot points are so where you have the geometry there but we actually still need these hinge points and again you we did not have these hinges we would just go into this our objects and again position those pivot points where we need them to be so we technically don't need those little cylinders but since we have them we can use them as our pivot rotation points so in addition to be centered here we also need to be sure we Center this in the width because if we didn't the axis Center would be offset so you need to make sure it's centered in all directions and then for the forearm you can see I already position this correctly so here's the anchor point there and probably need to just bring this anchor point so it's centered in the right view as well so you need to make sure the axis Center is centered in the front and the side views all right so if we set this up correctly we should be able to just move this up and down you can see we have our nice hinge or nice springboard action happening very cool so we can reset PSR the one thing I want to do is we have some overlapping geometry here so what I'll do is just grab our upper arm in our forearm geometry and just move this backwards a little bit and now you can see that with our hinges here every all of our geometry is actually not centered right so I'll just grab all that and just try to Center that try an eyeball it here and there we go so by holding by hiding our duplicate shoulder and hand objects and using a duplicate set up or I case set up as our right side so this is our right shoulder set up and there we go a nice mr. holder there we go basically just duplicating that and moving this up and down you can see we have a pretty nice springboard set up but you can see that as we move this around this can get kind of screwy and we'll just reset PSR so what we want to do want to do one last thing is that is to constrain the movement of this goal object to this goal null to only move in the Y direction so we want to lock everything else so we can do that by using a cinema 4d tag protection tag and what that's going to do is immediately lock everything you can see all of our axis point ease arrows are grayed out and you can see everything's locked and this is perfect for if you have like a camera setup and you like that angle of view you don't want to accidentally move that camera you want to save yourself from yourself this protection tag is perfect for doing that so what we're going to do is we don't need everything lock we need everything locked but B Y so what we're going to do is just do that and with that Y unlocked we can just move this in the Y and not and not have it move all over the place and again saving ourselves from ourselves so that we can only move this up and down in the Y so now always think we have to do is animate this goal but what we're going to actually do is use yet another handy option in the constraint tag menu and if I go and grab a constraint tag and again this is truly the Swiss Army knife of character tags because we have all these weird functions but the one that's really cool is this spring now if I turn this on you'll see that we have this spring option and if we define a target we can follow that target but this following object this main object we have the tag on will actually have spring movements applied to it so we're going to use this constraint spring tag to apply the springy bouncy movement to this so what this requires is that we actually animate another object so this can be constrained to it so what I'll do is I'll make a copy of my hand goal my main goal here and this will just be the follow null and then what I'll do is I'll delete this tag as we only need the constraint tag on this this goal here and now I can just keyframe this follow gnome and what I'll do is just for now I'll make this a child this goal a child of annul so I can actually see how far I can go and set keyframes before it's too much or too high so I'll just undo that so I'll go to my Salah no no and at frame 0 I'll set a keyframe for 0 in the Y and then I'll go about 45 frames and just bring this down and this will be just a slow a slow wind-up so maybe negative 70 set a keyframe and then this will just shoot up super fast to about 65 and then this will just go back to its original position which is 0 centimeters and now we have this kind of basic movement that we can now apply springiness to so what I'll do is I'll bring this goal from out from under the null and then to make this work all I'll have to do is drag and drop this follow null into that constraint spring target and then I just need to say I need this to follow the position of this follow null so I'll just check that on and now let's see what happens so our follow mill is the only thing that's animating in our constraint tag is clamping this goal to this null so let's see so go down you can see that it follows the null and it applies this cool springy movement to it so how cool is that so we just automated that springy motion so we have a lot of options here one being drag which adds some friction to this whole movement so you can see that the undulations dayal a lot quicker can actually get rid of the drag all together you can see that there's a lot of residual springy movements there we can up the stiffness which is the stiffness of the spring as well so you can see that because of that we're actually almost overextending our joint set up so we can do we can add some gravity as well to shrink this down or just add a little bit of drag or if this is going way too high springing over over it smacks and almost stretching the the rig out too much we can just go into our timeline and just go to our curves and maybe bring this down maybe not have it shoot up so high so there we go we added some nice spring movements with just our constraint tag set to spring all right so there is your little introduction into the world of mechanical I can rigs we covered forward kinematics inverse kinematics how to structure your object hierarchy and axis pivot points to be able to create a nice iCare it we went over I Kate eggs pulls goals constraint tags man we covered a lot and then we used it all to create a nice little spring board animation inside of cinema 4d do you have any questions about anything I covered in this tutorial be sure to ask them in the comment sections I'll try to help out as best I can and if you make anything using anything in this tutorial any techniques in this tutorial I'd love to see them be sure to post it and tag me on instagram on facebook on twitter love to see what you're making and if you like this tutorial be sure to hit the like button I'd really appreciate that and I really appreciate all of you out there watching my videos and I'll see you all in the next one alright everybody bye
Info
Channel: eyedesyn
Views: 150,993
Rating: 4.9541931 out of 5
Keywords: cinema 4d tutorial, c4d tutorial, c4d, cinema 4d, learn c4d, eyedesyn, c4d tut, tutorial, mechanical ik rigging, cinema 4d ik rigging, ik rigging, cinema 4d rigging tutorial, c4d rigging tutorial, cinema 4d IK tutorial, cinema 4d mechanical ik, cinema 4d constraint tag, cinema 4d constraint tag tutorial, cinema 4d constraint tag spring, c4d rigging, cinema 4d rigging, cinema 4d character rigging, cinema 4d character rigging tutorial, cinema 4d tutorial beginner, mograph
Id: nNZkFHFqs_k
Channel Id: undefined
Length: 25min 52sec (1552 seconds)
Published: Wed Mar 01 2017
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.