WEBVTT

00:04.340 --> 00:08.620
Hello everybody and welcome to this reminder video it's been a while since we've had one of these.

00:08.720 --> 00:14.420
Now when it comes to applying a transforms and physics it is incredibly important if we don't apply

00:14.420 --> 00:19.910
our transforms to the physics engine will think something is smaller or larger or weighs more or less

00:19.910 --> 00:22.190
than it should do compared to its volume.

00:22.190 --> 00:25.520
So you end up adjusting the density of something without even realizing.

00:25.640 --> 00:30.010
And obviously if you're trying to mimic brakes as we're going to do in this section then you're going

00:30.010 --> 00:33.620
to end up with something not acting as you would expect it to.

00:33.770 --> 00:35.430
So that is really important.

00:35.450 --> 00:39.230
So let's learn a bit more about applying transforms and how they're going to affect you in physics by

00:39.230 --> 00:41.640
hopping straight on over in a blender.

00:42.580 --> 00:46.150
Okay so we're back over in blender and we have two things in front of us.

00:46.150 --> 00:52.500
We've got three balls on each of these ramps these ramps are slightly downwards as you can see here

00:52.510 --> 00:54.150
they do have a slope to them.

00:54.200 --> 00:58.020
I've already set out the physics and will learn a lot more about that at the moment.

00:58.030 --> 01:01.710
We just need to focus on what happens if we don't apply it transforms.

01:01.720 --> 01:07.410
So the three balls on the left here and the ramp are a duplicate of these three balls on the right.

01:07.420 --> 01:11.410
The only difference is they they always the same.

01:11.620 --> 01:14.410
They all have the same friction and all the other set ups.

01:14.470 --> 01:17.740
But the difference between these two the one on the left.

01:17.740 --> 01:20.390
All of these have a scale factor of one.

01:20.410 --> 01:23.490
Now these ones on the right have a slightly different scale factor rubbering.

01:23.500 --> 01:24.990
Open the properties tab.

01:25.120 --> 01:29.480
If I select the one on the right here we can see it's got a scale of point one.

01:29.560 --> 01:35.200
This has a scale of one in the middle and then the one on the left has a scale of 10.

01:35.230 --> 01:39.550
So they will behave slightly differently depending on what they are.

01:39.550 --> 01:45.190
So in reality the one on the far left of this group of three is much smaller.

01:45.370 --> 01:49.010
And on the right is much larger by a factor of 10 both ways.

01:49.120 --> 01:54.890
So let's without any further do let's go ahead now and play the animation and see what happens.

01:55.760 --> 02:00.980
So the balls dropped down a little bit of a bounce to them and we see and there will be some randomness

02:00.980 --> 02:03.210
here that's just part of the physics engine itself.

02:03.230 --> 02:08.920
But we see that these three balls are pretty much going at the same speed down this ramp.

02:09.170 --> 02:13.050
And the smallest ball is going quicker than the medium ball.

02:13.070 --> 02:15.480
And then this one's barely moving it.

02:15.500 --> 02:16.860
I mean it is moving.

02:17.050 --> 02:19.020
You know they dropped off the end there.

02:19.190 --> 02:25.210
So this one here is slowly moving down but it's not behaving as you would expect it to.

02:25.370 --> 02:27.940
And this is something that will throw you a lot.

02:27.950 --> 02:34.280
When it comes to your animations especially if you're using the physics engine in it if you've not applied

02:34.280 --> 02:36.910
the scale it's not going to act as you would expect it to.

02:36.920 --> 02:41.360
And that could be obviously very annoying if you then go and tweak loader parameters and then realize

02:41.510 --> 02:45.360
I only had remembered to apply my scale.

02:45.530 --> 02:47.160
Now there are a couple of other things.

02:47.190 --> 02:53.450
Sometimes if you inadvertently apply the wrong location you can get some really weird results as well.

02:53.630 --> 02:57.640
And we had that warning in right back if you remember when we were doing the Skittles.

02:57.650 --> 03:02.840
If you've got the centre of mass or the origin of the object in the wrong place you'll end up doing

03:02.840 --> 03:04.790
weird things as well.

03:04.790 --> 03:10.170
In this case the origin of all of these objects of course is in the middle of them so we stop it here

03:10.760 --> 03:18.020
and let's go back to the normal default view that we'd have and we've got the origins right smack bang

03:18.020 --> 03:21.260
in the middle of each of these balls which is where it should be.

03:21.260 --> 03:22.900
That's where the centre of masses.

03:23.060 --> 03:29.480
If we decided to have a bit of fun of course and move that centre of mass slightly to one edge that's

03:29.580 --> 03:33.780
the centre of mass on top of this ball solona left click on the very top of the ball.

03:33.810 --> 03:35.060
I've run out of zoom.

03:35.130 --> 03:40.940
This happens so often you select it so we can zoom right in and put 3-d cursor on the top and in the

03:40.940 --> 03:47.690
tool shelf itself under the Tools Options set the origin to the 3D cursor.

03:47.690 --> 03:52.220
So now all of the mass of this ball is distributed on the very top.

03:52.340 --> 03:57.020
And I'm going to do the same on this one but this time on its side and then we're just going to laugh

03:57.060 --> 04:02.990
as it ends up Mexican being down the entire ramp this origins of 3-d cursor.

04:02.990 --> 04:07.760
So let's see what happens if we go ahead and do that because we've moved where the masses and we can

04:07.760 --> 04:12.890
see that these things are moving in a very weird way in fact I don't think the slope is big enough.

04:12.910 --> 04:15.860
But they're tending to go towards where that weight is.

04:15.860 --> 04:20.840
Perhaps I've been a bit too extreme on that mascara's distribution but there we go.

04:20.840 --> 04:30.620
So in this case this would be a case of in here going apply the location and then see what happens after

04:30.620 --> 04:31.610
that.

04:33.100 --> 04:34.120
Oh it's gone really weird.

04:34.120 --> 04:35.550
Now look at it go.

04:36.010 --> 04:41.560
I wonder how those amazing So if we go ahead and inadvertently have plied the location that's move the

04:41.560 --> 04:43.250
origin all the way over here.

04:43.270 --> 04:45.460
I've seen that happen so many times.

04:45.460 --> 04:50.650
So the origin is well back in the whole origin of the entire world at zero zero zero.

04:50.770 --> 04:55.990
The ball of course is nowhere near that so often in these cases if you've inadvertently done that's

04:56.020 --> 05:02.320
very easy to do you can go to set origin after the object is selected and move it to the centre of mass

05:02.350 --> 05:05.100
either by the surface or in this case of unadilla volume.

05:05.110 --> 05:10.600
And I can do the same here with this next one set origin to the centre of mass and we'll learn a lot

05:10.600 --> 05:12.230
more about that in the next lecture.

05:12.250 --> 05:15.860
But let's just make sure these are now going down as we would expect them to.

05:17.030 --> 05:18.190
Yes they are working.

05:18.200 --> 05:20.250
And let's just fix these here so we.

05:20.300 --> 05:26.360
If I select this one here and apply the scale and on the end apply the scale as well.

05:26.360 --> 05:30.110
Now we should see that they behave very much like each other.

05:30.110 --> 05:35.330
Of course there will be some randomness but we can see they're all falling at an appropriate rate for

05:35.330 --> 05:42.620
what they're doing and they should all reach the end pretty much together give or take a few frames

05:42.620 --> 05:43.280
difference.

05:43.280 --> 05:44.000
Perfect.

05:44.060 --> 05:49.430
So I hope that's clear that things and specifically why you need to apply your transforms when it comes

05:49.430 --> 05:50.620
to doing physics.

05:50.890 --> 05:53.570
And I will see you all in that next lecture.
