Beginner Guide to CGI in Blender

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey guys this is Steve lund with another CG geek blender tutorial and this is going to be a beginner's guide on visual effects and blender so in this video we're going to be taking some live footage camera tracking yet and then dropping a 3d model into it with some realistic reflections and shadows to blend it into our footage also add a little bit of foliage as you can see here - just really dumb give the illusion that it belongs in the shot and as you can see here we get a nice result where it looks like the model is in the shot but it really is not it's fake alright so to start we going to be using some of the features from blender 2.8 now blender 2.8 isn't out yet it will be out towards the end of 2017 but you can download the betas already so you want to go to builder blender.org links in the description and download the latest versions of blender where we can get some of the new features like the shadow catcher for example that will give us some some more ease of use and make doing this process simpler and easier and quicker if you want to shoot some of your own footage for visual effects check out the video I posted about two weeks ago on 10 tips for filming visual effects and just a lot of tips in there for different things like you want to make sure you have objects in the foreground and in the background you want to make sure that your footage isn't too blurry and etc alright so without further ado let's create a new scene in blender okay so in a new scene in blender here we're going to start by going to our movie clip editor so down in the corner you're going to click there and then switch to movie clip editor here we can open up our live footage there'll be links in the description where you can download the shot I used go ahead and click open and then we'll grab our footage and here you can see our shot like I said if you're interested in learning how to shoot footage for visual effects definitely check out that video I posted a few weeks back but just kind of cover some of the tips like writing down what the settings were when you shot your footage and stuff to make it handier and get a better result my camera tracking alright so first we want to change a few settings in our user preferences so often user preferences you want to go to system and then scroll down to your memory cache limit now this is going to be allowing how much RAM blender can use in the movie clip editor to basically cache in the footage for faster playback now I have 32 gigabytes of RAM so I'm going to go ahead and set this to about 8000 which is about 8 gigs of RAM depending on how much RAM you have you want to change that to more or less but I give it a good amount if you can now I'm going to switch to GSL because that just renders a little faster on GPU and I'm going to enable my GPUs for rendering ok so before we get into placing markers and tracking this footage we have to change a few of our presets here now I found that using fast motion worked best even though if I cash my footage in here like you want to do go ahead and hit alt a alt a and you can see that this light blue bar is the cached footage and as it's going through is caching it into the RAM so even though you can see that this isn't too blurry or anything there is a bit of fast motion in it and using the fast motion tracking preset will just work a lot better but you can see the char just kind of rotating around and panning around this this open graph area in this kind of scrap yard pile and we'll be adding a old car into this scrap yard alright so first off we're going to change our tracking preset to be fast motion that's going to give us just some better better tracks it's going to hold on to its tracks better not lose its location and then a few other settings I'd like to change is if I wire this up a little bit here extra settings I like to change the margin limit to be about 5 pixels this is basically when the track will stop tracking if it gets too close to the edge so really giving a little bit of like a 5 will make it stop before it goes to the edge to prevent it from accidentally sliding or something okay and one more setting that we can change is the motion model here it's a two location and rotation but for a scene like this without many square objects or square corners I'm just going to use location if you have a lot of like buildings or sharp edges rotation might help to get a better track but it really does nothing for a scene like this because nothing is super square in it and the rotation just doesn't really work very well alright so I also like to set my pattern size to 51 and make sure that you're on frame 1 before you start tracking so now where I frame 1 we can start placing trackers so to place the camera track marker it's really simple it's just control left-click so I'm going to start by just putting a tracker over on the window here and you can see that we get the little display there the tracker is on our window so now I'm going to click the track button right here it's also control T and hitting that you can see that the track goes throughout the entire footage real quick and follows that point exactly so the whole time it's locked on to that high contrast point and tracking through the whole scene so you want to pick a lot of high contrast areas in your footage to put camera trackers because that's going to give you the solidest tracked it's going to have the most information to grab onto and not let go you also want to avoid placing on a edge like this because for example this track would easily slide up and down trying to find what point to stick to so putting on a corner like this for example is going to work better and then getting tracks in the foreground and in the background so I'm going to track a few things in the background here just putting a few more on this building maybe one up on top there just so you can get a little more across your whole footage some in the middle ground and then some in the foreground here so the more you can get in the middle foreground and background the more you're going to get the accurate depth in your scene and more blender will kind of understand how the how the scene is laid out let me go ahead and continue just control left clicking placing tracks around I'll place one over here one over there anyway you can find a high contrast corner is going to be the best and with this shot in the scrap yard you have plenty plenty of different points to track so it works pretty well in this case but just putting tracks across the whole scene I recommend 12 to 15 tracks at a minimum you have to go more because the more you have the more you can be kind of picky with what you keep and what you delete later on when you're reconstructing your scene all right so there's a pretty good amount I'd like to get some more in the middle ground here where we'll be placing our 3d model Belle it's important to have some tracks on the the floor where your model will be going because that's going to make it a lot easier in reconstruction to get the scene orientated properly alright so just a few more markers around here one right there maybe put this up here actually it might work better if you if you place the market decide you want to move it you can move it with G so for example if I place it here I want to move it just like in 3d view you can hit G and just slide that tracker to where you want helps to kind of look at that magnifying area up there and yeah just getting getting some markers across your whole scene and different locations is basically the trick it goes pretty fast and it's actually pretty fun now I just want a few more here we'll put one there one there may be one here somewhere let's see if we can't find an area that we might get a good track we'll just try that okay so that looks like enough for now maybe one more in the foreground areas here let's see where I might be able get one to stick I will try one it there all right now hitting a and again making sure you're on frame one we're going to hit the track button again or hit ctrl T and watch all of our track markers go through the footage and track so it's kind of cool to watch this happen you know you can see them all kind of comping the same path once in a while you'll have one that like up here this one just has a mind of its own it's going all over the place so that one's not going to work we'll have to just delete that one but for the most part they seem like they're working pretty well and then it makes it to the end and finishes so yeah this one right off the bat I know I know failed let me go ahead and actually just try moving that to a new location I'm going to hit a to unselect everything grab that one again and let's see if we can't lock it onto this corner here instead now with everything unselected you want to make sure you don't select the tracks that you're happy u.s. select just that one track and then hit the tracking button and we'll go through with just that one with one tracker selected and you can see that that still isn't working very well there it's costing around a lot so we'll just move it to a new location again because if it's if there's a lot of errors in it it's really not worth it trying to fix it and it's better off to just try a new location and tracking it again and see if it sticks better alright so that one's jumping all over the place - not working just grab it again move it to another corner that maybe it will stick better - and then track all right now that one seems to be holding pretty taut and that one went the whole time so that would be a very nice solid track all right now to kind of check to see what tracks are good and what tracks are bad I find what it's helpful is to split your window here pull it up and you have a graph line here all your tracks we make it a little bit bigger and zoom out and looking at these tracks so you can see which ones are kind of out of place like this one for example you can tell that is not following the pattern of everything else very closely so there's probably an error with it so if we hover over it and kind of follow along this track in our preview you can see it loses point of its track and it's messed up so we know that this one needs some help so let's select just that track go to the beginning and let's try moving that to a new location let's try back here alright now with everything unselected we want whoops you can see I move all of the tracks there just ctrl Z that's where you want to make sure that everything is unselected when you grab a track so go ahead and move that back to there and we can track just this track again you can see that that looks well like it was working better for a while not entirely but it was working better until it made it to the edge there so what you can do is right when it makes it to the edge and you want to stop there have a clear option here so you click this button here and so we clear everything after that point so we'll just clear that the track doesn't have to go all the way to the end it's going to be helpful for when it when it is in the scene and that's going to be the same case for a few tracks like this one down here for example we just want to follow it until it goes out of the scene here and then we're going to clear it afterwards all right so that's looking pretty good and we have a few more spikes in our track here that's probably has issues let's go ahead and check those out real quick this track yep I track lost sight of its thing for its marker for a little bit there so let's just go ahead and redo that one and you can see this is kind of a process for for narrowing down your track now and clearing out the bad ones keeping the good ones is this one here is just going through and checking which ones are kind of spiking in your graph line and retracting them unbuttered points and in some cases if it's just a little bit bad like that was pretty bad I don't think I can use that one but if it's just a little bit bad you can fix it which I'll show you in a little bit but for now let's just try try getting this in a spot that is like check that nope still lost it right around here so let's see if we can't fix that I'm going to move to the point where it loses it right there I'm going to hit G to grab that track and move it we'll move it back to the corner there and then we'll hit track again and see if it doesn't stay there and yes it does so you can see just by fixing that one frame or it loses sight of its tracking marker we can get a good track throughout the whole scene so there we go now we have a nice solid track ok so there's going to be a few other ones that I have to kind of clean up here doing that same sort of process where you find the track this one here for example and I actually I think we already did that one yes we did ok that one's still ok but finding the tracks like this one seeing when they go off if they go off that one actually seems like it holds this spot very well and just correcting them so I'm looking like well this one's not very good but I'm kind of narrowing them down I'm just going to go ahead and finish this out using the same methods described if it's not working we would do a different spot if it's almost working well just try fixing that one spot and seeing if you can't get a bit of track so that one's just not working there so I could work with this track or I could just move it to a entire new location and try it from there subtract that and that one still slid around a little bit as you can see there so let's try moving it down here going whoops going to the beginning moving it down here and then tracking well and that one's just not working very well so if you get fresher to track just delete it you might not need that extra bit of information anyways and a one bad track is going to ruin the whole batch so just don't worry about it so now that most of my tracks are good let me go ahead and save my footage here and now I can kind of start doing some solving to find out which tracks are really bad and which tracks are actually going to be usable so to do this what you're going to do is select all of your tracks at first we have to set up our camera settings so this is why in my previous video I said it's important to write down your settings because here you're going to want to put your settings into blender for solving it this is the sensor size of your camera so I have a 4:3 for this footage here if you don't know what your footage is you'll want to Google and look it up alright then the lens was shot at 14 millimeter so when we go ahead and hit 14 for that and then this is just distortion settings which I like to have blender automatically calculates so we'll leave it at that and let's see what we get when we try and solve our camera motion so to do this we're going to switch to the solve tab right here clicking that we can go solve camera motion but first we're going to want to give it a keyframe now keyframes are basically just a point in footage where between two clips it kind of recognizes that kind of movement as a like a perspective change or something so it's just kind of like it's kind of guessing what's going to work best to get the best solves here in my experience sometimes just playing with different numbers gives you best results but I'm going to go ahead and describe this motion here this is kind of between frame 170 so pre Fame B will be 170 and 140 and we'll see how that's working so if you go soft camera now you can see that we got a self area of 195 that is terrible we can do better than that let's try let's try a different point in footage so the keyframes are the first things you want to kind of mess around with and see if that is the reason for the bad track I'm going to change that to 140 and BD that's just jumping back in time oops I can't get that at zero jumping back in time a little bit here and we'll see how that looks and you can see we're down to an eighth so just kind of playing around at the keyframing is a big factor I'm going to go ahead and tweak that a little bit more we'll change it to say 50 and see like it's better or worse well like it's a lot worse if you want to increase your key frame size move 70 still worse 80 is what we're at so now we'll try 90 and that's still bad so it likes keyframe 80 like I said there's just a little bit of random lucky in the key frames playing around with them you can get something that works well and then let's see if keyframe be going smaller it gets better or not like it's worse so we'll go bigger 145 like it's a little better 150 and it seems like this thing about the same now so we'll try 160 and that's worse so we'll stay at 150 and 80 and that gives us a pretty good solved track there so now what else we can do is have it refine the k1 and k2 that's basically the distortions the lens so have it solve that and you can see that it gets a little bit better if a salt air now sometimes having blender automatically choose where it thinks the correct focal length is will be beneficial so we'll try that and see if doing that doesn't improve our score of 8.01 or 0.05 a little bit and you can see that gives us a much worse result so putting that back to k1 k2 and making sure that the focal length is what we have set there at 14 millimeter is going to give us the best solve now you can see that that's just giving me kind of random results it's kind of freaking out a little bit and sometimes just changing the keyframes a lot by having it say automatically solve the keyframes usually this is a terrible option but we'll just do it now to kind of change it up and then take that back and put what we had and 80 and 140 will kind of reset it and you'll get your score back mix it up this time it's not doing that come on let's see there we go 80 point 6 now this blue line is kind of what it thinks the track is and when it kind of spikes you can see that thinks the track is off a little bit and when it's a 1 straighter it means you have a more even track so it's not very straight so this definitely some solving that needs to be done here so to kind of clean up our clips we can go to the cleanup menu here and we can select frames that have an air of what's in more than 12 so changing is to making sure it's set to select we can set the arrow to 12 and then say clean tracks and you want to make sure everything is unselected first then click clean tracks and you can see that these right here it thinks are pretty bad tracks so let's kind of grab that track here look at our preview there and scroll through and yep that's the terrible track so that could be one of the issues to our our high air so I'm just going to retract this one by grabbing it and moving it to a new point here and tracking so I'm gonna have to switch back to track here or hit ctrl T and track that through and you can see that looks like it's whoops I'm tracking all those tricks that's fine but um you can see that's a much better track you can see also that I accidentally tracked these two again but that's fine as I just have a duplicate here it looks like so I can delete one of those all right now this track is well it's actually pretty okay I think it moves around a little bit but I think it will be okay alright so let's go ahead and go solve camera motion again and we should have a better error you can see we're way down to four point two now so that was quite a bit better so again let's go ahead and clean tracks with an error now of eat or more so change out to 8 click clean tracks see this one this one's terrible just messin up our whole footage so we'll just delete it so if you want to worry about that track alright and so now we can jump to the beginning again self camera motion a 2.3 so that's getting close to being acceptable actually do it so now we can kind of do the same thing dropping our air down now to about five including tracks that have an air of five or more you can see this one is jumping around so that's why I grabbed that one and we just need to kind of relocate this track a little bit I'll try putting it over on the other side here and tracking it through control T and it's still kind of sliding around so it's not going to work we'll have to jump back to the beginning here and let's try moving it down to the bottom or let's try going to one of these in here all right control T that once terrible can't find that at all so just try a different point let's try it down here control T you can see there it looks like it's locked on much better so that will be a much more solid track all the way to the end and if we check our camera motion now you guessed it we're going to be better so where it's almost below - it's looking pretty good let's clean our tracks again you can see we have one here that it thinks is bad and yes it is so you can tell it the blender camera tracker is quite smart it knows when something went wrong and most times we will find it let move ahead and move this to the point here let's see if we can't control T get a better track out of that that looks pretty solid a much better track so let's go ahead and solve our camera motion again and now we're up a little higher so that is again just kind of the random randomness of it sometimes we will jump around in you a little bit but that's fine we'll just kind of find out what is higher than eight and we'll fix it so this one here it thinks is pretty bad but it's actually not terrible I think our tracks are actually getting pretty clean now and it might just be changing our keyframes at this point to get to a better solve see what this ones here did this one was wandering about on the ground there it's actually pretty solid okay so let's save our footage and let's play with our key frames a little bit here see if we can't get that lower now and there we go we down to one point three let's see if we can push it any further by going to 90 then we're back to four so right around there we get a one point three and that's in the acceptable range so with that set I think our tracks are pretty clean let's go to an air of to clean tracks and just check the ones that signs to see if we have any problems with it we see there's this one move around too much well it's pretty solid all right let's try one of these other ones that I've found this one here for example all right these are ones that just kind of jump around a little bit but really aren't too bad you can see right there it jumps and so I might want to fix that just by going to the Frank before it jumps and then to the frame where it jumps hitting G pulling it back to match it up like the frame before it using the arrow keys can jump back and forth and then control t make sure everything else is selected control T and finish that track out and that looks a little bit more solid let's see if our salt air goes down at all by solving the camera motion again and it went up so again change your key frames a little bit and see if you can't get it back down it's just a little random I'm not exactly sure why it does that but it will happen to you from time to time and don't panic you can get it back okay so I think that this is the track now that will be good enough to work with it looks like all of our tracks are quite stable they all look pretty similar let's check this one here yep looks pretty good and we should be ready to start dropping footage into it a one point three is in the acceptable range in my book and you can do more refining if you wanted but I'm pretty happy with it so save our footage and let's move on to the next step okay so first we want to switch to cycles render because we'll be doing this in cycles and then in our setup here in the soft tab we can scroll down and set us backgrounds that's going to put our footage as a camera background which will make it more appropriate for us and not more perfect more intuitive for us to work with and then we want to set up some tracking parameters here so you can click set up tracking scene and what having a problem with that right now and that's fine we don't need that just forget about that that might be something to do with the beta air right now but let's set up some orientation then so this is like setting the scale and floor is going to be our main goal here so for scale just pick two tracks that you kind of know the distance between now I know this is about a meter and this is in meters so we'll go ahead and set the scale to that and then for the floor that's going to be important let's grab three tracks you need three different tracks to kind of find a floor we'll grab those and I like to switch to 3d view here and go to camera view and if I go set up background yeah we get our footage back there I had to do that again not sure why but just do that and then go set as floor and you can see this kind of changes the orientation now that's not not perfect so I'll try these three tracks set us floor I need only three so four and that looks a bit better let's try this track here though see if that works better all right that looks pretty good you can see it's getting getting pretty close to our floor now the scale is still a little big in my opinion so let's try it setting the scale since these two that's a little smaller it's a little better maybe the floor would be better with these three I mean not quite nice it's scale or four all right so let's just kind of continue finding the floor out of these not really getting a great result but we might have to just make one of these work okay we can we can tweak this now in 3d view so with a camera selected let's kind of rotate this to fit the floor a little bit better I'm just kind of hitting double tapping our and lining up the axis is to match up on our grid for a little bit better something like that basically you want the grid floor to kind of match the orientation of your scene so in perspective to what the camera is that you want to create for to be basically the floor and that looks pretty good there so let's go ahead and save and we can do a little test here actually by grabbing our cube kind of lifting it up onto the grid floor let's go to the side view here scaling it down a bit alright placing it right about there and then seeing how it sticks to your scene now you can see there's actually quite a bit of sliding so the problem for that is that our scene is not orientated properly with our our grid and you can tell if you go to a side view here let me just kinda jump out that the tracking markers which should be the ground for the grid floor is not reaching it so because of scale calculations in our tracking scene Winston's really working properly we can just grab our camera and scale them manually let's scale that up a bit and then I'm going to hit G and drop it down so these tracks that we know we're kind of on the floor another graph are going to be on line with that green bar so right around there is going to be a bit better alright so now if I I'm at all for this one do it slight bit of rotating there something like that so now if I go to camera view and I play this back you can see that that cube sticks to our footage way better and that actually looks pretty good so that should work that should work well so now we can kind of bring in our actual object but first I actually want to get the the reflections set up so I'm going to just kind of move this cube out of the way and I'm going to add in a UV sphere so shift 8 add an UV sphere now you can hit control 2 to add a subdivision surface to that and then we can over in our settings here let me see go to make it a little bit bigger you know what we can move into our 3d view completely now so let's just go closing this off and hit smooth shading there so now inside view I'm going to hit number pad 1 and move that sphere up so it's sitting on the ground there scale it down a bit in size and hit Z and just kind of drop it on to the floor there now this is I'm going to make a mirrored ball to do that I'm just going to split my window real quick so I can open up the node editor and here just close off these windows with n I'm going to add a material to this so new material and then give that material a glossy so right now let's diffuse I'm just going to click on that node and hit X shift a shader velocity so add in a glossy shader connect that to the surface and give it a roughness value of about point zero zero two so it's mostly mirrored okay so now you can see that it will be completely glossy if I want to read it view but before I do that I want to open up my environment map now if you watched my 10 tips on filming footage for visual effects you'll see that I shot an environment map and I recommend to always shoot an environment map of the location that you shot your footage this can be done with pretty much any cell phone nowadays so if you interesting to not get the app for that but we go ahead and open that up now so I'm going to go to my world settings choose use nodes I can uncheck the ambient occlusion that's turned on by automatic in the camera tracker but I don't need it and I'm going to open up my environment map so I'm going to choose environment texture there and then click open and I'm going to grab the environment map that I shot believe it's this one so now if I hit numpad 5 to jump to my camera settings I'm going to turn on GPU just for rendering and rendered and now you can see my my world is in the scene and this is basically an environment map of location that I shot that footage yet awesome so now what I can do is in camera view I want to orientate the the glossiness from my scene to match that at the footage so do this it's very simple I'm going to switch to my world nodes right here click that you can see we have our environment image they're connected to our background like I just did here so every time you change something over here it's also changing over here I'm just going to hit shift a add in a texture coordinate so right there input texture coordinate and then a converter mapping node vector mapping node like generated and connect that to the vector and then the vector to the vector now this is just some tools to orientate our our background so it lines up with our footage so I'm going to a rendered view and I want to place that house in the background here like you could see in the video I'm going to rotate along the Z until the house is roughly in the corner there that's about all I have to do so now you can see if I go to transparent here in my render tab choose transparent you can see that we have realistic reflections going on in our scene so that's pretty cool you can see scrubbing through here that we have our ball sticking to our floor and if we go to rendered it's going to be reflecting everything in the scene awesome but we're not finished yet what we're gonna do now is we're going to add shadows so what I'm going to do for that is go shift a and add in a plane with my cursor in the center there if it's not you can hit shift s cursor to Center and then shift a add in a plane scale that up to be about appropriate for your scene something like that's good and then hit em and move it to the bottom layer all right so this is because we want it on two different layers because we'll be adding them together later so go ahead a hold shift now and click that thought I want to turn that layer on and up in our render layer settings here you can see that we have two settings the foreground in the background the the background is this shadow layer basically and you can see here if you click background is on layer one or two I guess this would be and foreground is on layer one so that's perfect and we also have a set that the foreground is going to mask the bottom layer this was all set up by default though when we clicked the the renders the set up tracking scene settings so if you didn't click that go ahead and click it and all right so now with this plane selected we can go to our render settings here and this is where you will need to be using blender to point eight of 2.9 beta or 2.78 beta I'm sorry but the the blender builds version right now like I said the beginning so you'll want to make sure using that otherwise you won't see this setting if you're already running 122.8 then you're in the future or 2.78 I'm sorry again then you're in the future and you'll already have the setting anyways so go ahead and choose shadow catcher this is a really cool setting which basically means that this object is nothing but catching shadows so if I go rendered you'll see nothing but the shadow and not that plane and that's perfect because we want it to we want it to be just there for the shadows all right we can drop that cube a little bit down and the last thing is going to be to set up lighting so I'm going to grab the lamp here that comes in the scene by default and I'm going to change it to a Sun lamp so click Sun under your lamp settings click use nodes I'm going to give it just a tiny bit of an orange hue to kind of match our footage and then I'm going to give it a strength of about 7 now I just kind of want to orientate it to match the Sun in my scene now I know it was a pretty late Sun it was kind of coming across the scene like this and maybe slightly rotated all right so I'm just moving around my middle mouse cursor here and that looks about the proper Sun angle so now going into my camera settings so you're rendered you can see it we have the shadow nice and long they're kind of matching the shadows and everything else you can tweak this if it's just a little bit too long of shadows you think or something but I think that looks about right let's go ahead and give this cube material just give it a darker gray all right now the last thing we're going to do actually I think that's about two things left is add the motion blur so for motion blur you need to go to your render settings here you're going to go down to motion blur and just check that box there and this is basically the shutter speed that it was shot at now I know this was shot at about a 120th on my camera or something like that around those lines so just dropping this down to about a point one one two maybe is going to be enough motion blur if you want to increase that you can really see the motion blur going on but we want to match the footage so you can see this is working now if you go to our spot where there's kind of jumpiness in your scene like so and hit save I'm gonna hit f12 to render it and you can see well it's still pretty sharp but I want to change it to be more just so you guys can see what I'm talking about and I also want to change my GPU tile size here real quick if you're running on GPU you're better off rendering on a bigger title size okay so doing a quick render here you should be able to see that motion blur yeah in effect but that's way too much so I'm going to turn that way down to about well maybe just a point to so we can see a little bit more of it all right so now going render we can see what it's looking like all combined so there's our object there's our Eddowes you might might make that plane a little bit bigger if we're leaving the Sun at that angle and give that a second to render there we go and then I right now we're getting black and that is just because we haven't set it up in the compositor yet but we'll do that in a second so I might want to make my Sun angle a little less severe I don't think it's quite so harsh and let's make this plane a little bit bigger just so it covers all the shadows we can kind of move it over there so it's more space all right cool and now you also might have noticed the amount of fireflies in the scene we can set a few settings here to kind of correct that in the sea here in light paths we can choose filter glossy you give that a 1 and that's going to help quite a bit so now for a render we should see that being being yeah much less fireflies they call it the noise the highlights all right so this is rendering out pretty quick now you can see that we fixed that shadow issue by moving the plane and we're ready to add everything kind of together to see it working once that's done we'll go ahead and add the the final vehicle into our scene to get kind of a cool model so now I want to switch to my compositor save and you can see we have some nodes here these will kind of messed up from the automatic thing I guess is not working quite right now but that's fine we don't need them we can just delete them and then we can add them in ourselves so we're going to want a render layer so input render layers we can duplicate this so we have our background and our foreground change the bottom one to background and then we're going to want to add in our movie clip so at input movie clip you can see that movie is already there it's from before and then there is one other option and that is movie Distortion you want to make it undistorted so drop that in and then drop the clip onto that cool so that's all we really need now we're just going to use some alpha over nodes so we drop in an alpha over and we're going to start with our footage in the top socket and our shadows bottom socket so if you go to that now you can see it's our footage with the shadows in it and you don't have to worry about any of these settings it really don't make a difference in this case but now I'm going to duplicate that alpha over node one more time shift D click and drop in this in the bottom socket now so our objects you can see there's our objects added to our scene and uh it's looking pretty good except for the fact that you might have noticed that you see the white surface in the shot and you don't want that so to fix that all you have to do is grab our floor here and in our render settings here cycle settings change it to not show up in glossy the diffuse the volume scatter and transmission if you do that when you render it again which I'll do real quick here just by clicking that render box on the Mirrorball you can see all those no composite so I forgot to jump in one note here and that's the input composite node let me see here where is it at output composite node okay you grab that one connect that up real quick now click that render option once more and you'll see that the white in our scene let's go on so that is something that we want to get rid of cool now you can see that that mirror ball is fitting nicely into our scene perfect and I think we can add a little bit more motion blur to our scene as well so when I crank that up to about 0.25 or maybe just a point 3 all right so now we're ready to add an actual object not just a glossy ball but an actual object to our scene so one thing that we need to need to fix here is our scales off a little bit we want our render scene here to be the same as movie clip well actually we want the movie clip to be the same as our render scene and you can see this is rendered at 50% so all I have to do is drop in a distort scale node drop it in here and change it to render size now you can see the size is back to being how it was before and there you have it there's our reflections or shadows all combined in with live footage so I'm going to save my blender file and we're going to add an actual object to our scene so for the objects that I chose there was a model I found off blend swap it was by Chris Kuhn I believe shout-out to Chris Q and thanks for making these awesome models and giving them away for free you can go ahead and download that with the link in the description but I go ahead and import that now let me go to default here close it out and I'm just going to move my two objects here to a different layer so hit M moving to a different layer and then I'm going to go file append and this is how you grab a file or a blend file from a different blend let me go ahead and jump to my right here Max's interceptor action I'm just gonna grab the one I tweaked a little bit here and I'll give a link to it in the description so Max's interceptor there we have it you just have to grab that green box to really orientate it and I'm just going to rotate around it on the z axis here a little bit place it in our shot wherever we want if you hit Z kind of see-through something like that I think I want to scale it up a little bit more that looks about right and then I have to raise it up so the tires aren't falling to the ground too much something around their looks looks about right though maybe it's a little bit high in which case um well actually I want to drop the camera down just a little bit yeah because you want to make sure that your tracking markers are on the ground I think it actually looks pretty good though and so now if we go let's pull it forward just a little bit more there yeah a little closer to the camera and one other thing you can do is to your camera settings here you can give it a little bit of depth of field now let's not much depth of field in this scene I just click limits there but you can go ahead and set up the depth of field just in case you might notice it in some scenes so to change the distance here and now because I clicked the limits you can see we have this crosshair we just want to line that up on our object of focus and then type in the aperture that you shot your footage with now I know this was about a aperture of 8 so I'm going to go how to put 8 well I might go something slightly lower just because you won't notice it anyways but just so in case you might notice it a little bit it'll be a little something there alright so now we have our object and it's dropped in our scene if I go rendered we can see what this is looking like here give it a second to load everything up and whoa I have to change that to a pitcher or f-stop sorry there we go so there's our object in our scene and it's looking at looking pretty cool few things though I think the scale is off a little bit a little bit too big and it's not really blending that well you can see that the tires are kind of sitting on the grass weird and that's why like I said in the beginning we want to add in some vegetation so I'm going to be using some grass from my nature asset pack if you're interested in picking up the nature asset pack yourself it's in the blender market just for ten bucks otherwise I have a tutorial well there'll be a link on the screen right now for that well you can go create some of your own grass to drop in your scene so either one of those works and go ahead and get the grass so I'm going to go ahead and append nach as well usually grab the graph file right there that I already have set up and again I want to move these to a different layer so these are my graphs my grasp objects I'm just going to move them to go down to that letter and now I'm going to add in a new plane so layer one I'm going to shift a and in the plane scale it up a little bit tab into edit mode with tab hit W subdivide and we're going to do that multiple times so we have enough vertices to work with there and now I'm going to go to particle settings new particle system I'm going to choose hair which use advanced scroll down start off we're going to fast here I know this is going quick but these are very simple settings and you can pull the video down if you need to really see what I'm cooking but just scrolling down going group and then choosing the grass group I'm going to choose rotation they're all standing up in the right orientation and now I'm going to go to weight paint and I'm going to painting where I want this grass so now I'm going to go option H in object mode I'm going to go option H whoops going to move my car object to the right layer it's on the wrong layer right now move it to layer one and I also need to move my lamp to both layers so hold shift and click that and now it's on both layers so it's on the bottom layer and the top layer cool so now just on layer one I'm going to go to weight paint mode and I'm going to paint in where I want the grass to be on my scene so I'm going to make sure my setting is set right so to draw with the strength of about 0.4 three should work I'm going to paint in around the tires here I want to add in some CG grass basically to kind of blend it in to our scene and make it look realistic so just around the tires and kind of underneath the car where you really kind of see it the only places you have to worry about so something like that is going to go a long way in realism all right so that's looking pretty good now that I have that wait paint map made I can go down into vertex groups and select that group right there in the density you can see it's all tucked around our tires you can also choose length this is going to give it the length of the group so the areas and more dense are going to be longer and I'm just like crank fives up a bit the random size is up a bit and then I'm going to choose rotation check that box on rotation change the phase and then the random phase so they're not orientated all the same way and then we can drop the amount down so just be something like 300 we don't need too much grass so if we go rendered now we can see that we have give it a second and there you have it we have our graph around our tires now you can see there's some black in the grass that's just because we need to go to our render settings here and in our light paths we need to give it more transparent classes i'm just--my give that 32 on both of them and then one more thing we don't want the plane with the particles on it to render so you scroll down and you click emitter uncheck it so it doesn't render the emitter so when I switch to rendered view we'll see just the grass and not the plane all right so that's very cool and we should be ready to render our scene so I'm going to go ahead and turn on both those layers go to camera view save our scene and go ahead and hit f12 to render ok and this is what we're getting so it's looking it's looking okay but there's definitely a few areas that need some work our shadows are a little harsh so you can tone those down a little bit at least soften them up a little bit by what I'm going to do is I'm going to go to the some settings so let me kind of keep this window up so we can see where our result is looking like we're going to a three view and our Sun settings make the size of it to be a little less large so it's a little softer shadows going to a point zero six let's just going to make the shadows a little bit softer now secondly I want to turn off a few things on our background layer so automatically is set up to take the shadow and AO but that's just slowing down our render time a little bit we don't need to worry about that and another tip is you don't need as many samples for your background so you can give the background scene about 64 samples and that's all you really need for the background because you don't need as many samples on the shadows as you do like the glossy materials on your truck or car whatever you're putting into your you've seen so there we have it those two settings changed we can do another render and kind of see if we're getting an acceptable results now I think that's going to do it let's go ahead and give her one more render see what she's looking like okay and then we have a little softer shadows and we can do some more tweaks in the compositor now so you get a nice finished result so switching back to the compositor again first off we don't want a hundred percent shadows so because we do this in two layers we can take our bottom layer now and turn it down to just be about 0.92 maybe a little bit more if you want to kind of get exact holding down alt and clicking you can see the black white red red green and blue values so you can kind of match the darkest shadow on your scene which is pretty dark right here it's about a 0-0 4 to the darkest shadow and your footage which is about well not quite that dark it's about a 0:09 same over here so that kind of means that you can check the shadows to your to a little bit that kinda means that our shadows are a little bit too dark here so we can lighten them up a little bit more by changing the the factor of how much we added in so now if I hit alt and click it you can see that without a point is zero zero three point zero zero four point zero eight so it's looking better maybe just a little bit less still and that's looking looking a little bit better now we can do some color grading to kind of blend this in a little bit better as well and that's going to be hitting shift a editing in a color color balance node now I usually use the color formula here but this is actually will be more accurate switching it to the offset slope so just go ahead and do that now this is our black value into our scene basically and because there's nothing that's completely black in our scene because of the the way the footage is shot I can take this and make it a little less black pretty close to black so about a point zero seven is about good I think but not completely black so I'm going to also give it a little bit of an orange hue just because everything else's or red hue I'm going to give that a point six point six leaving that at point seven so everything is a little bit orange II Nam and that looks that looks pretty good now you can change a little bit of the other colors like the power you might want to make that well you want to go very subtle but you might want to make that slightly bluish which is going to give you actually a slightly orange color that's just the way these work but um I don't know the technical aspects of it but I just know how to use it barely so now we're going to also want to give it a little bit of an orange color here just to kind of match the shots all right and here we can kind of change the exposures a little bit too by brightening these just to kind of match the whites and blacks of our scene a little bit better but that looks pretty good something around there doesn't look bad and again you might want to take the shadows a little bit lighter just because it a little bit harsh but overall I'd say that looks that looks pretty realistic so yeah you can do as much tweaking as you want but you can see that the grass we added in is blending it into the scene a little bit better one thing is the sharpness is the sea-mist a little bit over the sharp so what I'll do sometimes is just add in a blur node so go ahead and add a blow note there's a handful different blend nodes you can use I actually found that using the bokade blur we turn down look the best up it's way too high but if you make its way turn down just like a point zero one let's go a little more see you for seeing it point one is a little bit too harsh maybe the point zero five a little bit more maybe just so you get that tiny bit of blur that kind of makes it match your footage because over the sharp footage doesn't work so yeah there we have it I'm just hitting if you're wondering Adam zooming in its V and alt TV I'm just zooming in here and now you can see that the blurriness kind of matches that of the footage so it looks a bit better so there you have it guys that is the the visual effects compositing now the last thing I want to show you guys is how to render this out as an animation because I'm sure a lot of you guys are asking that and sometimes to get upset if I skip that if my tutorials so I'm going to quick show you how to do that so first off you want to set up your render settings set the a frame rate to be the twenty nine like it was shot you can make it a hundred percent if you want or you can render it out at half resolution but for your final one you want to go a hundred percent choose your file format now first you're going to render it as a image sequence this is just because if you're running it as a movie file and it gets cancelled halfway through it you can't resume it but if it's an image sequence you can always resume to the last image saved out and continue so I'm just going to change it to JPEG you're just going to choose a location on your on your hard drive where you want to save files out and then you pretty much ready to go so you're gonna click render animation and it's going to go through and render every frame one after another now I'm not going to do this I already rendered these scenes out but if you want to do that you just leave that go and it would jump from frame 1 all the way to frame 250 rendering them out now I'm going to cancel that because I want to do that but um and if it got cancelled somewhere in it in the middle there you know without it being finished you would just uncheck overwrite and then rendering in the same folder click render animation and it will automatically resume at the last frame rendered so that's a nice little feature okay so once you have all your frames saved out then you're going to save your project and you go to your movie clip editor and video editor here you're going to jump to frame 1 and hit shift a and an image then you're going to grab your frames here you can see I have all the frames rendered out I'm going to hit a to select all of the frames and then add image strip as you can see we have a long strip here and that's all of our images loaded in if I scrub through it you can see it's our car in our footage like so and if you want to save this now as a video file you would go back to defaults you would go to your render settings here you change it to something like well I don't really have many options here but usually I have like an h.264 option I don't have it here because this is the early version of blender but you would change to something like h.264 and then in your encoding samples change it to something like mp4 but for now you can do an avi render or something doesn't matter if you're on a Mac you might have some QuickTime options there so you might want to set it to that but pick a movie formats and then you go render animation and then it's going to render really quickly just out of the video sequence editor saving out a movie file as you can see is doing a sequence render now just putting all your frames together let me cancel that again but that's how it's done so that's going to wrap things up guys I hope you enjoyed this video tutorial series not serious but just video on doing visual effects in blender let me know if you like the video with the thumbs up let me know if you did like the video with the thumbs down leave your thoughts in the comments below leave a suggestion for a future tutorial maybe and I'll see you guys in a future video so bye
Info
Channel: CG Geek
Views: 411,489
Rating: undefined out of 5
Keywords: CGI, VFX, Blender, Tutorial, How to, Hollywood, Effects, Realistic, beginner, easy
Id: 5EofgP6mOXI
Channel Id: undefined
Length: 56min 57sec (3417 seconds)
Published: Fri May 12 2017
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.