Coding 8, Blender Final Projects

Today I finished 8th Grade Coding! Yay me! 

Here are all of the completed projects I have done in Blender this year:

Definitions:

  • Rendering – changing your ‘rough’ scene into the ‘final draft.’

Rain

Before rendering

After rendering

Fun fact: I modelled raindrops so they would look more realistic.

Pinball Machine

This is not the best thing I have made in Blender, but it was my first time 3D modelling.  I can animate it so the ball falls through and falls out of the machine.

Waving Flag in the Wind

Like the pinball machine, I can animate the scene so you can see the flag move.  The circle on the left is the wind simulation.

Frame zero:

Frame 50:

Frame 100:

That is all of the projects I have made in Blender this year!

Coding 8, Section 14 – Rendering

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Currently, I am doing the fourteenth section in the course, Rendering.

The fourteenth section in Pixar in a Box has two parts: “Rendering 101” and “Mathematics of Rendering.”  I will not be doing the second section because it is meant for 12th graders.

Part One

In this section I learned how Pixar artists render, the last step of making a Pixar movie.

I first learned what ray tracing is.  When the film finally reaches the Render Farm (what Pixar artists calls the Rendering department), the artists have to color each pixel on the screen on at a time. To make it easier the artist will put a camera in the scene and follow the ray that is projected, like this:

You can move the grid with the slide controls and touch each pixel by moving your mouse to the certain pixel on the small grid on the left.

I also learned how lighting matters when rendering.  Under a light dull surfaces, like tennis ball of a book are known as diffuse lights.  While shiny surfaces, like a pool ball or a hardcover textbook, are known as specular lights.

Notice how the pool ball has a slight reflection of the light, that is an example specular light.  The tennis ball has no reflection, which is an example of diffuse light.

That is all for this section!  This is the last section of Pixar in a Box.  More coding projects are coming!  Thanks for reading!

Coding 8, Section 13 – Sets and Staging

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Currently, I am doing the thirteenth section in the course, Sets and Staging.

The thirteenth section in Pixar in a Box has two parts: “Geometric Transformations” and “Mathematics of Rotations.”  I will not be doing the second section because it is for high schoolers and uses trigonometry, which I am not familiar with.

Part One

In part one I learned how to make sets for movies.  In the pictures below, you can see the scenes I made.  In the final exercise I was able to scale, rotate, and translate (move), the items around the room.  I also learned that you have to translate, scale, and rotate the items in a certain order or the scene will not come out the way you want it to.  First you must scale the item, then rotate, then move or translate, to its spot on the screen.

I also learned about commutativity.  Commutativity is when order does not matter.  In this case, the order of how you scale, rotate, and translate.  When creating your scene, it is non-commutative, which means the order of the steps matter.  But when something is commutative, it means the order does not matter.

Example: if you scale an item by 5 then translate by 10, it will not look like translate by 10 then scale by 5.

Example: if you put the x position of the item then the y position, it will look the same as putting the y position then the x position.

That is all for this essay!  My next essay will be about the fourteenth, and last section of Pixar in a Box from Khan Academy, Rendering.  Thanks for reading!

Coding 8, Section 12 – Crowds

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Currently, I am doing the twelfth section in the course, crowds.

The twelfth section in Pixar in a Box has two parts: “Building Crowds” and “Counting Crowds.”

Part One

In this part of Crowds, I learned how artists at Pixar make crowds.  This part was based on Wall-E, a movie that came out in 2008.  If you have never watched Wall-E, it is about “a machine responsible for cleaning a waste-covered Earth meets another robot and falls in love with her. Together, they set out on a journey that will alter the fate of mankind.”

In the movie there are multiple scenes where there are crowds of robots.  For the animators, animating each and every individual robot will be tiring and tedious.  So the artists have to make multiple different robots, but make it easy for the animators.

This is where combinations come in handy.  If you have not learned about combinations in math yet, it is exactly what it sounds like.  It is combinations, in this case, of heads, bodies, and arms.  For example, if you have two heads and three bodies, you can make six different unique robots (2 x 6).

In this part I made different robots with combinations.  Here are some pictures of what I did:

Part Two

Part two, is all about the math behind combinations.  In the first exercise I learned a formula to find possible robot combinations for a robot with two heads, one body, and one set of arms.

R stands for the number of robots you can make.

B stands for the number of bodies you can use.

A stands for the number of arms you can use.

H stands for the number of heads you can use.

r = h * (h – 1) * b * a

In the second exercise I learned how many possible combinations there can be for a snake.

I also learned a new formula, the binomial coeffient. 

Say that you want a cast of 3 robots, and you have 6 different robots to pick from. 

You would write 6 * 5* 4/ 3! or 6 * 5 *4/ 3 * 2 * 1

The exclamation mark after 3 is known as a factorial (in case you did not know). 

Another way to write this is 6!/3!

That is known as the binomial coefficient, which can also be written like this:

n stands for the number of actors, in this case robots you can choose from.

k stands for the size of the cast, which is 3 in my example.

That is all for this section!  My next essay will be about Section 13 of Pixar in a Box on Khan Academy, Sets and Staging.  Thanks for reading!

Coding 8, Section 11 – Character Modeling

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Currently, I am doing the eleventh section in the course, animation.

The eleventh section in Pixar in a Box has two parts: “Modeling with Subdivision Surfaces” and “Mathematics of Subdivision.”

Part One

Subdivisions.  What are they?  Subdivisions are mathematical formulas, and at Pixar they are used to construct the characters in each film.  Subdivisions are much more expressive compared to parabolas, which is why they are used instead of parabolas.

This is what a subdivision looks like.  There are commands that let you make the blue dots, this is called splitting.  And when you split, you can average the points, which makes the shape rounded.  You can control the shape by using the four points, A, B, C, and D.  Splitting and averaging, in technical terms, is known as subdividing.  

In the third exercise, I was able to work with subdivisions.  I could add points and make the shape smooth.  This gave me a feel of what Pixar artists do to make characters for their films.

Before:

After.  This is my best attempt at making a hand:

In exercise four, I learned how to subdivide with 3D shapes!  I was able to work with a cube, a ring, and a hand.  This is one of my favorite exercises!  I can almost imagine Pixar artists doing this everyday as work.

Part Two

Part two was all about the math behind modeling.  I learned about weights, weights are how far the object moves when you subdivide.  For one of the exercises I was able to play around with the weights to see what happens when I use certain weights.  I learned that when you have three weights and you use negative and positive numbers you create a fractal.

This is what a fractal looks like after you subdivide:

That is all for this essay!  My next essay will be on the 12th Section of Pixar in a Box on Khan Academy, Crowds. 

Thanks for reading!

Coding 8, Section 10 Environment Modeling

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Currently, I am doing the tenth section in the course, animation.

The tenth section in Pixar in a Box has two parts: “Modeling Grass with Parabolas” and “Calculating Parabolas.”

Part One

The first exercise I did was labeled “String Art”.  In the video lesson before the exercise, it explained that when making blades of grass for a movie, they use Parabolas.  There is a lot of math behind this, but that will be in part two. 

A more art friendly version of Parabolas are string art like this:

The green in the picture above is what the blade of grass would look like.

In the second exercise, I learned how the find the coordinate of a point between two points. 

In a line segment, the middle point is ‘Q’, and the two end points are ‘A’ and ‘B’, you have to find the coordinates for ‘Q’.  The formula for this is Q = A/2 + B/ 2.

The third exercise was quite simple.  I was given a blue and green curve, and it was my job to move the blue curve right above the green curve.

Before:

After:

For the fourth exercise, I was able to make my own blade of grass!  I was able to control the width, color, and angle of the blade of grass.

For the fifth exercise I animated multiple blades of grass.

Part Two

In the first part I learnt about the art in environment modeling, in the second part I am learning about the math behind the art!

Imagine there is a line with points A and B at the end.  In the middle, there is M.  But in this case, M is not in the middle of the line, but favoring B. Like this:

The formula for this line is (1 – t) A +tB

T stands for the distance between each point on the line.

In the second and third exercises I had to calculate the touching point.  But what is a touching point?

The point P on the picture above is the touching point.  The formulas in the picture are how to calculate P.

That is all I have learned in the 10th section of Environment Modeling.  My next essay will be about Section 11, Character Modeling.

Coding 8, Section 9 Animation

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Currently, I am doing the ninth section in the course, animation.

The ninth section in Pixar in a Box has two parts: “Introduction to Animation” and “Mathematics of Animation Curves.”

Part One

In the first exercise I animated a ball across the screen.  You press the frame you want and drag the ball to the position you want.  The animation looks really cool, but it is not very natural and looks jerky.

In the second exercise I could only animate the ball up and down.  I was not able to move it around the screen.  The animation looks really cool, but it is still jerky and you can tell it is animated.

In the third exercise I learned about Bezier curves.  Bezier curves make it easy to ease the animation into its next position.  The purple curves that you see below are known as splines, they make curves which eases the yellow dots (the positions we want our animation to go to) into a nice curve.  This makes the animation smooth and natural.

It may look messy, but the animation is a lot smoother and natural compared to the two earlier animations.

In the fourth exercise I learned about avars.  Avars is short for animation variables.  In this exercise I learned how to squish and stretch the ball to make it look more natural while it is bouncing.  ‘S’ stands for scale, and ‘Y’ stands for its height on the screen.  ‘S’ and ‘Y’ are examples of avars.

The last exercise in the first part of the Animation section was making my own animation. 

Here is the link to my animation:

https://www.khanacademy.org/computer-programming/animation-last-exercise-animating-the-ball-with-x-y-scale-and-rotation/4837905338679296

Part Two

Part two of animation is all about learning the math behind the cool animations.

In part two I learned about was linear interpolation.  Linear interpolation is “a method of curve fitting using linear polynomials to construct new data points within the range of a discrete set of known data points.”[i]

In the first exercise I had to solve the x position of a certain frame using the linear interpolation formula:

x coordinate – x coordinate, divided by, frame – frame.


Let’s plug in the numbers, and maybe the formula will make more sense.  In this case the equation would look like:

30-18, divided by, 14-4 = 1.2

Now, to find the x-coordinate in frame 7, I add 1.2 from frame 4 (because it is the first frame that has a given x-coordinate) to frame 7.

The x-coordinate in frame 7 is 21.6

When the line is sloping down instead of up, the answer to the formula would be negative, which means the x-coordinate decreases. 

I also learned about De Casteljau’s Algorithm, which is ways you can make shapes or curves with more than two points. In the picture below you can see little grey dots.  Those are connecting and forming the curve.

This was all I learned in Section 9: Animation.  The next section I am going to do is Environment Modeling.  Thanks for reading!

[i] https://en.wikipedia.org/wiki/Linear_interpolation

Coding 8, Section 8 Rigging

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy.  Right now I am doing the eighth section in the course.

The eighth section in the Pixar in a Box course is rigging. There are two part of this section, “Introduction to Rigging” and “Code a Character”.

Part One

The first exercise I did was rigging the classic Pixar lamp.  With special controls, called deformers, I could adjust the position of its head, arms, and base.  Then I could use deformers to control where the lamp is on the screen and how high up.  It is known as “sizing the x and y of the lamp.”  The x is where on the screen the lamp is, the y is how high the lamp is on the screen.  At the end of part one I was able to animate the lamp!

I also rigged a snowman’s face by control the size, direction, and position of its mouth, eyes, eyebrows, and hat.

Part Two

In part two of the lesson I coded my own character using JS (JavaScript).  The picture shows the snowman I made.  In this lesson I connected all of the body parts so that when I rotate the head the hat follows it and when I rotate the body the head follows.  This makes it easier for me to move things around.  I no longer need to adjust controls for every body part.

This was all of the exercises I did in the eighth section of Pixar in a Box!  The next section I am doing is Animation!

Coding 8, Section 7 Patterns

For 8th grade Science/Coding I am doing Pixar in a Box in Khan Academy. Right now I am doing the seventh section in the course.

The seventh section in the Pixar in a Box course is patterns. There are two part of this section, “Geometry of Dinosaur Skin” and Painting with Randomness”.

Part One

The first part of the lesson is based off of the Good Dinosaur movie. It focused on how the animators at Pixar made dinosaur skin for Arlo (the dinosaur). I learned about how patterns work.  Each part of the dinosaur scales are made of sites.  You can think of sites as little dots, around these dots or sites, are lines.  These are called cells, these make up the scales of Arlo.

I also learned about something called a Voronoi Partition.  A Voronoi Partition is something that we see in everyday life.  The Voronoi Partition can be seen in the skin of giraffes.  To explain what this is, I’ll use bubbles.  When you blow bubbles they all merge together, right?  Imagine two small bubbles next to each other with a small dot in the center.  We call the dot a site.  When you blow up the bubbles they get bigger and merge into each other.  Each bubble is known as a cell, and the lines around them are known as boundaries.  Something cool about Voronoi Partition is that if you choose a random point on a boundary it is the same distance away from the two nearest sites.  And when three lines meet it makes a vertex, it is also an equal distance away from the three nearest sites.

At the end of part one I was able to make my own dinosaur skin!  I was able to control the color of the skin, the size and color of the scales, and how far the scales will extrude from the leg.

I unfortunately, was not able to put the picture of the dinosaur skin into this post.

Part Two

In Part Two I learned about low and high resolution.  It is how close the camera sees something.  Low resolution is seeing something from really far away and high resolution is seeing something that is really enlarged.  I also learned about Perlin noise.  To put it in laymen terms, it can control color in animation using resolution.

I was able to make my own dinosaur skin at the end of the lesson.  This time I was able to control the resolution of the skin and scales.

I unfortunately, could not put a picture of my second dinosaur skin into this post.

That was what I learned from Section 7, Patterns of Khan Academy’s Pixar in a Box course.  The next essay will be about Section 8, Rigging.

Thanks for reading!

Design a site like this with WordPress.com
Get started