A Beginner's Guide to Camera Tracking in Blender 4.0

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
camera tracking is one of the most important things to master for any visual effects artist now that blender 4.0 is out I thought I'd update my blender camera tracking tutorial so you can get to tracking on your own like always if you want to follow along with me I have everything I use down below also make sure to watch the entire video since there are a few more tricks I've learned since the previous tutorial okay so here is the scene we're going to be tracking today hopefully we can get a similar result to this let's go ahead and open up a new project I'm just going to work in the general workspace and then I'm going to go ahead and come up here VFX and motion tracking and let's go ahead and open up our footage now I went ahead and converted my video into a image sequence just because it's not tied down to any frame rate and so it'll be much easier to work with so I'm going to hit a to select everything open the clip and first thing I notice is that the color is off so I'm going to come up here to color management and down to standard uh so that fixes the color then we want to come up to the tracking settings and go ahead and set the scene frames and prefetch our footage all that does is just make our playback a little bit smoother so now into the actual camera tracking we need to go ahead and control click and that'll add a marker and ALT s will reveal the search area so A good rule of thumb is to find areas of high contrast that don't move throughout your footage and you do want to make sure it's kind of in different points throughout your footage if they're all kind of localized in this one area it's not really going to give us a great track also you want to make sure you pick a adequate pattern size and search size ones that's not too big or too small since that'll really affect your camera tracking so something like this is actually pretty decent for my scene so I'm just going to keep it on the default values over here okay so next I'm going to go ahead and delete everything okay so before we get into camera tracking let's go ahead and set up some some of the settings so for match I'm going to set it to priest frame I just find it works a little bit better and then if we hit normalize on that'll basically change the luminance value so if any luminous changes happens it's not going to actually affect our track and finally I like to come over here to the tracking settings extra and set the correlation to A9 that basically just means that blender has to be 90% sure the track is correct for it to continue tracking these are just kind of the settings that I automatically set up inside a blender of course you can play around with them and get a good kind of workflow for your own needs okay so I want to start at the very very first frame of our footage and let's go ahead and detect some features you can see that blender's automatically selected some of the features up there let's go ahead and decrease the threshold to a 0.01 and then a distance to an 80 and what we're trying to do here is just get as many markers as possible so blender has many points of reference so that we can uh eventually Whittle down into the best possible tracking markers and so let's go ahead and contrl t That'll track the markers forward and you can see down here it's made a graph of all the markers so we can keep track of everything what I want to go ahead and do is now that we have all the mark starting from the beginning of the footage I want to go ahead and go to the end of footage and go ahead and detect some more features and then what we can do is control shift T and that'll actually track all of these markers backwards and so now we have markers at the beginning of the footage and we also have markers at the end of the footage we need to go ahead and set uh markers at the middle of the footage as well uh so let's detect some features again contrl T to track those forward and then I'm going to come back to that frame 75 for me and then control uh shift T to track those backwards Okay so now we have the beginning middle and end now these trackers are worthless uh since we don't have a actual camera solve and so what we can go ahead and do is I want to come to the solt tab and before we do anything I want to go ahead and try to get out as many bad markers that I can visually tell as possible so a good way to do that is to come down to the graph editor and what we can see is we have all of the kind of individual markers graphed out into this kind of uh range right here and what we can do is we want to select any outlier that we see visibly uh visibly on the graph and so you'll see these green kind of spikes all throughout our footage and that is actually errors uh you know in the tracking in blender if I actually select this one at the end uh you can kind of visually see what I'm talking about uh if we kind of scroll throughout the area where there's this big spike you'll notice that it starts to kind of move all Haywire on this wall and so we don't want that we want to try to get out as many of those as possible so again to do that we're just going to come down to the graph and delete all of the kind of spikes that we see uh both in the green and the red uh just trying to get those out as much as possible I see more in the uh in the the green sorry than the red and so now we can see our graph is much more clean looking and of course we do want to come uh bring this down here now and we kind of want to do a visual pass ourselves of just kind of you know scrubbing throughout the footage and if you see any markers that kind of jump around and stuff you just want to go ahead and manually delete those but I think we're good for this shot now let's go ahead and get a camera solve now the am key frame is basically a frame range where there is going to be the most kind of Parallax that blender is going to be using in order to actually give us a cameraa and so what we want to do is we want to have an area where there's a lot of markers kind of moving in the foreground and there's also a lot of markers moving in the background and so what we can see is that we have a lot of kind of blue uh you know long blue lines here and if I come kind of over here you'll notice that towards here there's not as many long blue lines this video is actually pretty good in terms of The Parallax so it really doesn't matter the am key frame as much as other videos but for the sake of demonstration I'm just going to select what I believe to be the most Parallax which is frame uh 20 into 60 and so I'm just going to uh kind of write those up there so 20 to 60 or I'm just going to go ahead and let blender refine everything let uh blender do all the work and go ahead and solve the C motion okay so we got a solve error of a 2.6 which is pretty decent we want to try to get that as low as possible I believe anything below A3 is pretty good I usually try to stick to below A2 so let's try to get that this is my favorite part of camera tracking is actually whittling down the solve eror so let's go ahead and clean up some of the tracks so we're going to let blender do all the heavy lifting again we're going to go to the cleanup section clean tracks and then that'll open up this menu down here we basically just want to increase this reprojection error all the way up until we're basically just skimming off kind of the higher projection error uh markers and so once we have kind of a few selected up here we want to go ahead and delete those tracks and then we can resolve the camera motion and so that's basically deleting all the bad tracker markers and we can see that we have a lower solve error because of it let's go ahead and clean the tracks a couple more times to try to get that as low as possible the reason we're not doing it all at once is because I actually find that if you do it all at once it'll actually select some potentially good markers and it might lead to higher solve errors overall so one more time we're going to clean the tracks and just push push this up until we get a few more GS remember blender only needs eight tracks in the entire frame to actually get a camera track however the more the better for modeling but also for the actual Soler so I went ahead and cleaned it up a few more times and was able to get it down to a.2 so hopefully you guys get a similar result and nothing goes wrong there now let's actually go ahead and set up a 3D scene so we can place some objects inside of it so if I pull this window down here and I'm just going to right click in the middle and join the area so I can see this a little bit nicer what I want to go ahead and do is scroll all the way to the bottom here set up the background and tracking scene and now we can see that we actually have some objects and the camera in our scene uh it's not correctly orientated you can see that our cube is kind of floating in midair and so what we want to do is go ahead and uh tell blender where the actual floor of our ground is so what I'm going to do is I'm going to come I know I you know if I was going to place something in the scene I want the object to kind of be around this area and so over on the side we have this orientation Tab and so what the orientation tab is going to allow us to rotate and actually set up the ground plane and so first let's select three kind of points on the ground so these three are pretty good you can always you know change around a little bit later so I'm going to hit floor down here and you can see it's orientated our floor a little bit nicer I can't really tell what's going on uh but let's go ahead and you know Define the origin and you know the rotation of scene so I'm going to select this point to be our origin and then this point to be our uh x-axis again it's really hard to tell because everything is zoomed in and this is actually the most important step is to actually Define the scale of our scene now if you actually shot your own footage on the day you should have taken some measurements of the actual scene so you can get super uh accurate results but again this is a footage I found online so we're kind of try to guesstimate a little bit um I'll no notice that this is about maybe you know 78t give or take uh something like that and so let's go ahead and convert that into me meters since that's what uh kind of distance scale that blender uses and so if I just type in 8T to meters we can see that we have uh 2.44 and so let's just go ahead and set the scale uh 2.44 and now we can see that's much more accurate to the actual scene this is very important for depth of field and also motion blur and you know pretty much everything in your scene so you do want to make sure you nail down the scaling uh again for this shot I'm not really going to be going into it too much because this is footage I found online so I'm kind of guesstimating a little bit here and so now we pretty much have the scenes set up let's come out to the layout tab and go into the camera view and now we can see that we have everything uh in our scene I'm going to go ahead and hit tab a g z uh control click that up one unit so that the origin is on our ground and let's just scale this down a little bit you know maybe move it over here and hide our ground plane and so if I go ahead and play this you can see that our cube is roughly following uh you know the ground and where it would actually be what I do notice is that the ground plane is kind of tilted and so let's go ahead and change that let's come back out to the motion tracking Tab and then I want to uh select three other points since the points I selected before weren't that great okay so let's select three more points so I'm going to select these three points right here and then set the floor and you can see that much better right now and then we can go ahead I'm going to sel this one to be the origin and then this one to be our x-axis the scale uh should have uh should have remained the same so we don't have to touch that let's come back out to layout tab and this looks much nicer you can see it follows you know the horizon line very nice and this is where you want to make sure your camera track is as perfect as you can and so what I'm going to do is find a feature on the ground I'm actually going to select the camera up here and go into the background images and just change the opacity up so we can see uh much better and I'll see this little dot on the ground I basically want to align this edge of my Cube to the dot you do want to make sure your cube is lying on the uh ground plane of the entire scene you can see this red line so that's very important I'm going to go ahead and hold uh G and then shift Z to move on every axis but the z-axis I'm just going to line it up to that little point right there in theory if we kind of zoom in here you'll notice that the corner kind of touches that entire Point throughout the entirety of the shot so that's how you know we got a pretty good camera track so now for a few final things for you beginners out there that I kind of want to go over uh if you come up here we can go ahead and turn the motion tracking markers back on you can play around with the turn that down a little bit and also make the camera path if you so want to uh just so we can see the actual line inside blender uh if for whatever reason if you're modeling that out uh that's how you enable that I'm going to go ahead and disable that and blender automatically sets up some stuff in our scene so I'm going to go and delete the forground and background uh collections right there also the background view layer we can just go ahead and exit out of that in the compositing tab you'll notice that we have all these nodes set up and I just like to go ahead and delete these kind of four nodes and plug the image into the the alpha over all of this was kind of just stuff that blender automatically set up when we set up the tracking scene and I just find deleting all that stuff kind of makes the scene a little bit more simplified uh for beginners let's come back out to the layout tab uh if we hit all H to unhide everything blender automatically set up a ground plane and if we go into the Cycles Render engine which is what you're going to be using uh for a majority of your visual effect shots if you care about realism if we go ahead and go into rendered we'll see that this kind of ground object is automatically set up to be a shadow catcher you see it more easily if we come up and go to film and change that to transparent so we can see the background and now you'll see that we actually just have this plane kind of affecting the shadow so that's how it's automatically set up pretty nice that blender automatically does that also very very important when we are actually solving the camera track inside blender it automatically accounted for Distortion so we have to turn that off uh because it's actually wrong as we see on the 3D viewport right here so to do that let's come up to camera go down to camera settings and then we want to go ahead and uncheck mark this render undistorted and if I if I go ahead and flip that on and off you can see that it's automatically kind of zooming in the shot and basically if we try to model out as we see on the viewport it's actually going to be wrong if we composit it in the compositing section as you see here again just a watch out there since I have ran into problems okay so that's pretty much the workflow for 80% of the shots that you're going to be doing inside blender the other 20% that are maybe a little bit more difficult I highly recommend that you guys do it in other programs uh since that'll take your V effect shots to the next level anyways thank you so much for watching and if you made it this far it'd mean a lot to me if you consider liking and subscribing for future videos but anyway I will see you in the next tutorial
Info
Channel: Jacob Zirkle
Views: 19,253
Rating: undefined out of 5
Keywords: blender, blender tutorial, vfx, beginner blender tutorial, vfx blender, blender vfx tutorial, blender beginner vfx tutorial, beginner vfx tutorial, blender vfx, vfx in blender tutorial, easy vfx in blender, blender beginner tutorial, blender beginner, blender beginner vfx, camera tracking, blender 4.0, blender 4.0 tutorial, blender 4.0 features, blender 4.0 alpha
Id: ui0JUHE12k8
Channel Id: undefined
Length: 12min 35sec (755 seconds)
Published: Mon Nov 27 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.