Welcome to solving camera emotion.
So this is going to be all about setting up camera movement and indeed working out whether the tracking
we've just done is any good for our scene.
You'll need the right camera details.
I don't know if I've mentioned that before.
I think I have.
It is important whether you've got the camera details by faffing around for hours to try and get them
or indeed you know the camera details because you've got the spec it is important to have the right
camera detail so go ahead make sure that's one of the first things we get sorted.
We're going to check the accuracy of our markers as we go through as well.
Now I was quite thorough but I might have missed one as I was going through because it may have looked
on a sort of zoomed out scale like it wasn't jerking about too much.
But we will go through and check the accuracy of our markers and dump any that are causing us problems.
Now an average camera solve error of less than one is ideal but that's not always necessary.
We may have a camera solve error of six and it work out to be absolutely fine.
We do have to test and assess as we go through.
You may have to refine your markers more.
It may be that one of your markers is causing a big problem see how to get rid of it.
There's lots of options and alley ways we can go down.
But let's go ahead now and set up the camera movement over in blender.
Okay so I've just re opened my file and the first thing I've noticed is my lovely light blue line where
it was cash before is no longer cash.
Now that's not surprising because obviously if you shut down blender is going to lose anything that's
temporarily stored so I'm going to go up to the top on my tall shelf and instead of just playing the
clip as we've done before I can go ahead and pre fret fetch and the short cut there is.
P It will prefetch the frames from the disc for faster playback and tracking and we can see that is
a lot quicker than it was just hitting play.
And now we should be able to scrub through we can see it's consuming around seven were seven point two
gigs this time round.
I can hit reload now reload is a bit pointless.
In certain cases it's only if you've edited the file on the disc itself on your computer.
And now I'm going to have the prefetch again anyway.
So we've got that now in our buffer and ready to go and we can just go ahead and go to the next tab
down on the tall shelf which is the sole tab.
Now before we do anything else let's just click solve.
Camera motion and see what happens.
Wow.
Okay.
I was not expecting that.
After all the trials and tribulations are been through trying to actually work out this scene I've got
to solve error and we can see on the head above the clip editor of three point six which is a great
start.
It turns out I may need do nothing more but will go through and refine it anyway.
Oh and before we do anything else you know what I haven't done.
I said it was the first thing we're going to do I got distracted by this blue bar.
We need to go over to the propertys and go to camera and set it to full frame and scroll down to lens
and set it to 20 because that is what the dji Phantom for's lens configuration is said to be.
Let's go ahead and click solve camera motion and it goes up to six point five.
Okay we can work with that is not great that it's gone up but we can play with the settings now and
work out what we can do.
Now one of the things we can do now we've got a solver error is we can have a look at individual tracking
points and they will all have an average error attributed to them.
So if you've got something that's got a high average error you may find and you say may find because
it does vary removing it from the scene can improve your particular odds of getting a good solve.
So after clicking through all of those I can see there that one seven point six before I do anything
else I'm going to save my work extra.
I'm just going to delete this Bush entirely.
So we got a average solara of three point six now before we do anything else.
I do want to just highlight occasionally when you hit solve camera motion again you get a different
result.
So let's go ahead and remove this one that's rated on an average of an average error of seven point
six on the propertys panel here we can see if that by removing it we get a better results of three point
six solve.
Camera two point nine two that's much better.
Now I'm going to guess here if I go through and remove the one that's five point six.
All right.
Is there anything else that's above 4 that's going to be my metric here.
And of course I need eight of these.
Ah well that's really low.
So let's see anything here that's above for I think there was.
Ah there's one that's five.
So let's get rid of that.
Now again getting rid of it may not have been the answer we may it may be better to refine it but let's
solve now were on two point nine one point eight.
This is getting better and better.
Incidentally you can look at this graph Ed and it gives us an idea of the actual what's going on in
terms of these markers and if they're jerking about too much and if they are jerking about that may
cause us problems there.
I'm really happy that we're down to one point eight.
So I'm not going to do anything else for the moment because I need to check and see what that looks
like being lean about it.
So I'm going to scroll down on the tool shelf to scene set up and click Set as background which scan.
This particular video has the background on the camera view.
I'm going to set up a tracking scene as well.
I'm now going to go over to the default layouts and from this view I'm going to watch the camera and
make sure it's not doing anything crazy.
If it starts doing crazy things and wobbling about that can cause issues out there are a few jerks at
the beginning and a few around.
Let's just watch here.
Around 180 or so.
Let's look at it from the camera.
And now this will slow down tremendously.
Now the important thing to note here is I'm going to have to hold down Shift to move.
But I want to have a close eye at the cube itself or the ground.
What I want to make sure is as this is playing through the timeline that it's not jerking about horribly
and then it's consistent So if the cubes covering up part of our scene that it remains covering up part
of that scene and not sliding and jerking all over the place.
If it does slide and jerk all over the place it just may look horrible.
In the end now because I'm going for an aircraft flying over the surface I can probably get away with
a bit more jerk than I would do normally.
Now I'm going to pause it there and go back to the beginning.
Now is sluggish doing this.
But I do want to just highlight this beginning bit if we have a look at the scene now.
It jerks all over the place.
You see that twitching it was only for a couple of frames but it's still very noticeable.
Now there's something I can do here.
That's really easy.
I get my starting frame and I set it at 10:00.
I'm not quite sure actually where that wobble occurred but I'm pretty sure as buelow 10 hour the 10th
frame so that's one way of dealing with that just cut it off it was a problem right at the beginning.
Who cares if no one sees the first half a second.
However if you do need to make sure that that works we need to investigate why it wobbles and it will
wobble like it does.
There we can see that it's shifting from one place to another.
And we as a whole scene is shifting because of some reason I can't tell you from here.
I need to go back into the motion tracking you.
And let's have a look at the graph editor of this point and see if we can gleam any information as to
what is going on here.
So one of these I can see is jerking and moving in the preview pane here.
In fact the one we've got selected.
So all of a sudden it jerks from one place to another.
So we can literally go in and fix that for this one particular frame that it's wrong on.
And place it.
Not sure where each frame was eeva side.
And that's always a good place to check a case that has fixed that one.
Could it be an Nach just that one was jerking all over the place.
No that also has a big shift to it.
I don't know what was going on at the beginning so I'm just going to move it over here.
So it's literally frame one frame to frame three is fine.
So let's go to the next one and I may have to repeat this several times in order to refine it.
Does this also jump.
It does.
How bizarre that each one happens now because it's every every time.
And rather consistent annoyingly consistent.
I can pretty much go through and fix all of these because it looks like they just need to be moved over
ever so slightly.
Does this one whatever it does does it do the same as some knee jerk.
Yes it does.
So there's something in the footage there that's causing it to jerk about and I don't like it.
I'm going to go away and fix this little issue and I see you guys back in a few moments.
In fact it looks like here that the issue stems from the camera not moving for one particular frame
or perhaps are a problem with the video it could be something along those lines.
But it looks like all of these frames are just shifted over by a tiny tiny amount.
It looks like just placing the marker on top of the previous one is working absolutely fine which seems
a bit of a cop out really out of thoughts.
There was a fundamental reason why it was doing that.
But it seems to have affect every one browser is a skip in the video but it doesn't take too long to
go through and just move everyone over everyone else.
So I think that's now sorted.
Now I have done that.
I'm going to have to go through and solve the camera motion again way down to one point eighty two as
a couple of other things we can do to make sure things are a bit more steady.
Now we've got a key frame a in a key frame B in this is where your 8 frames have to exist.
If I said Keen frame A to 0 and press solve camera motion you'll get the error at least eight common
tracks need to be there for reconstruction.
What do you pick in order to what key frames do you pick.
Well usually you pick the cleanest area of your footage for.
So from 1 to 30 is only that much.
Is that enough.
Well we could pick from 10 too.
Where does this stop moving around 70 let's do tend to 70 and see if we get a better solve error because
of that two point six.
So the answer there is no by picking that one but maybe 70 to a hundred and fifty.
This is one of these ones where you can go through and you can check.
So we get about a result one point a to have the whole lot from frame 1 to frame what our 230 solve
caromed motion three point three two.
So there are various ones that are good.
There are various ones that are worse.
One to 20 gives us two point six one to 40 gives us one point eight.
So back to that one point eight.
If that looks like a pretty good setting and then once more hop back to the foreign again if you got
a 3D view open you can hop back to us was around for can review and see let's see what happens now over
those first few frames.
It's no longer jerking about.
So now we have a 3-d scene set up being tracked.
That means we can start placing things in this scene and giving them things like shadows.
Oh.
Oh there was a little jerk there.
This is why this playback is very important.
Is that going to make a difference in the playback.
Possibly so.
I'm not sure where that was but I'm going to go and play it back and have another look.
And of course it's time for you guys to have a challenge.
I'd like you to go ahead and get a good camera solve.
So aim for a low error rate.
Now I have been rather fortunate in this particular scene that I've managed to get it so low so quickly.
That doesn't always happen.
And you often do have to refine and that just comes with practice and getting used to how the marker's
act what bounds you set them in.
And sometimes it's just the luck of the footage.
Some footage is a lot harder to track than others.
Remember to check the actual footage speaking about it.
You can actually see little wobbles as it's going through in the preview.
Pain in the properties panel helps with that.
Is it stable enough.
Now this refers specifically to the 3D editor.
So when you're looking through the camera with the background turned on are you seeing the cube or the
ground plane that's placed there.
Slide abouts on your scene or do they look like they're part of the scene.
If they look like they're part of the scene that's probably stable enough.
I've got a couple of those little jerks I can go through and fix and I would want to fix them for completeness.
However thinking about it at the same time if I've just got a plane flying over a over the surface a
little jerk may not actually be apparent in the video.
So it's worthwhile knowing.
Refine your markers add new or even delete more markers if necessary.
If you find that brings the solara down.
Then go ahead and sort that out.
Now check the track preview in the properties panel isn't wobbling about too much.
That should look pretty static throughout the entire time line playback.
If it's not then you know there's somewhere else.
You can focus your eye a word and it's certainly great as previewing each one of the markers you've
got in that panel and making sure it's not jumping about.
Now I think I've spotted another jump.
I'm going to have to have a closer look at that and I think it's similar to what happened before the
one we fixed.
So go ahead pause a video now and go get yourself a good camera solve.
Okay guys.
Welcome back.
Let's hop back on over in a blender.
Okay so let's go and see if we can refine this even further.
I'm going to go straight back to the motion tracking side of things.
And let's have a look and see what we can do now.
Obviously selected everything there don't want everything selected can be a dangerous thing to do.
And I was playing about's and I managed to get an average solver of one for five when I was playing
about.
So just a word of warning.
It is quite easy to screw things up and I set my key frames here back to 40 and solve camera motion.
There we go back down to a sensible level down back down to five point six.
Now one of the things I did notice and I was doing a bit of reading on camera sensors and really into
my photography and I realize that camera sensors when they're doing video often don't use the full sensor
with they are smaller.
They use part of the sensor.
Now that will have the effect of each other.
We could either lower the sensor width making it smaller or we can go ahead and change the focal length
because they're interchangeable sort of.
So the smaller the smaller the sensor the larger the larger the apparent focal length.
And we can see that these things are linked because as I move one the other moves as well.
So it's going to work out to be slightly smaller do we make the sensor smaller all that would make sense.
So let's make the sensor with 35 mil and do solve camera motion.
Five point six let's do thirty three point six thirty two five point six.
It looks like we're locked at five point six there.
Does it work.
If we move our way a minute right now is moving that of course it will be locked in and I just told
you guys that it moves about it will move this other one.
So it makes more sense to change the focal length.
So now with the focal length it would go the other way it would go up apparent size.
So let's go through 22 has gone to 16 that's go to 24.
And as God to all one point nine now that's starting to look good.
So 24 Let's try 23 because these numbers do jump about are point seven nine brillion.
I'm really happy that that's worked out.
So I'm just going to Prescot solve Kara motion again.
My eyes are not deceiving me.
So it does look like with the information we've got here.
We can say that the focal length when taking a for a video on this particular device works out to be
roughly twenty three millimetres give or take.
I'm not going to take that as a given for the moment but there we go we've got that sorted.
Let's see how this looks when we go back to our 3-d view.
Let's go back to the faults and play that through now we've got the camisoles starting from frame 1.
So still a little bit of a jerk at the beginning that I need to go back and sorts.
And there was another one.
You need to be keen eyed.
There it is.
And that's around frame 45 something like that sir.
I need to have a closer look at those.
I'm going to go do that now and see you guys back in a few moments.
Hey so I'm busy going through these particular key frames and taking a close look at them as it as we're
approaching I'm going to jump through with a timeline here.
We reach frame 48 49 50.
It jumps and then at some point it comes back again.
Now what we can see on the graph editor at the top is we can actually see this the Vission this this
jumpier the marker we've got selected and we've got this green party here.
That is what we're looking at.
So as we come through we can see that that is where all of a sudden jerks and then jerks back again.
The other way as it corrects itself now in this particular case it does look like hucking.
Just go back in time to where the error occurs and just re track forward from that point.
And that does appear to solve the issue.
Of course I still need to do that for all of the markers in our scene but that's somewhat better than
having to manually place them all.
So again this seems to go wrong frame 49.
Does this also have a dip on the graph.
Yes it does.
So again I'm going to play that forward how we can see it smoothes out those great big dips.
Now we've got another dip here so if I go to frame forty nine.
I'm just literally going to jump there at this point and just play forward from here.
It also jumps there are play that forward and that smoothed out the dip as well.
So it looks like during the tracks it has mucked up somewhere.
It's as simple as that does this jerk about around there or not.
Yes something happens a bit around the same area.
In fact now is not as pronounced because the movement isn't as pronounced.
It's as simple as that so if I play forward that should have solved that and it should have read tracts.
Yes it has.
And again I have to go through the recipes and sort that out.
I'll be back in a few moments.
And I'm back again.
And I think I've fixed all of my little problems.
I've toyed about with the focal length for twenty two point eight.
With all of these fixed all of these markers face I'm getting a Solve error of point 6 three which is
excellent.
I can now go to my default view and just play back what I've got.
I've also decided just truncates the very beginning at five frame five.
And as we go through I can't see any sudden jerks which is exactly what I'm looking for because now
I can go ahead and build up the 3D scene with the plane flying through it's exciting stuff.
How did you guys get on.
I hope you've managed to place your cube and plane your ground plane in this scene so that it looks
as if it's part of it.
Obviously it doesn't look like it's at the moment because we've got nothing applied to these models.
However we're well on our way now to making this work.
Shea a work in the discussions perhaps a little animated gif of what's going on.
And I will see you guys in the next lecture.