Linux Format

RENDER: Getting started in 3D

Even if you’ve never used Blender before, Michael Reed will have you blending like a pro by the end of this tutorial.

- Michael Reed has been exploring Linux since first trying his hand with Slackware in 1996.

Even if you’ve never used Blender before, Michael Reed will have you blending like a pro by the end of this tutorial.

There’s no doubt about it, Blender is an amazing piece of software. It’s a complete 3D graphics creation applicatio­n with sections for modelling and sculpting, texturing, animation, physics simulation and many other areas. Whatever area of 3D graphics and animation you’re interested in, once you have

Blender installed, you have a profession­al-level applicatio­n at your disposal.

However, as good as Blender is, it’s necessaril­y complicate­d because 3D graphics is a complicate­d subject. We’re going to take you though the basics of modelling in Blender and give you an introducti­on to the program in general.

When you first load the program up, you’re presented with a 3D cube and what seems like millions of icons, menus and panels. So hang around while we stretch that cube, spin it around and make it dance for us.

Getting started

Let’s start our journey to becoming masters of the cube, and eventually, moving beyond it. When you first load up Blender, you’re in what’s called Object mode. This enables you to select and manipulate objects that you can see in the main area of the screen (called the Viewport). You can orbit the starting cube by moving the mouse around while holding down the middle button, and you can move around the scene by holding down Shift while moving the mouse. Zoom in and out by scrolling the mouse wheel.

Let’s start doing things to the cube. Click the left mouse button on the cube to select it. It should now be outlined in yellow. Hover over the main toolbar (left-hand side of the viewport) until you find the Move icon and click it. You should see red, green and blue arrows coming out of the cube. Click and drag those arrows to move the cube around in each of the three axes.

Try the tool below the Move tool, which is the Rotate tool. You should see red, green and blue circles around the cube. Click and drag those to rotate the cube in one of three axes.

Next down the toolbar is the Scale icon, and it works in a similar way to the tools that we’ve already encountere­d. You can scale an object in one of three axes or scale the entire object at once by clicking and dragging on the white circle.

Locate the Object Properties tab in the Properties Browser on the lower right-hand side of the screen. Note that as you change the position, rotation and scale of an object, the correspond­ing fields in the panel also change.

It’s possible to become confused about which axis is which, or you can find yourself needing a rough idea about aspects such as size and position. In those cases, it’s often easiest to move things around, visually, in the Viewport, using the tools that we’ve discussed and then make the precise changes in the Object Properties tab afterwards.

For example, if you wanted to turn an object on its side by rotating it 90 degrees, it’s often easiest to rotate

it manually first, to get a rough idea, and then change the rotation to exactly 90 degrees in the panel.

Access Edit mode

Start by selecting File>new>general from the menu bar, to set us back to the beginning, with the default cube in the default position. So far, we’ve been playing around with Object mode, so let’s take a trip into Edit mode. Select the cube and then select Edit mode from the mode selector above the toolbar (or press Tab).

The first thing that you might notice about Edit mode is that the toolbar has extended itself with extra tools. You will also notice that the cube itself has extra details on it. You can also see that each corner of the cube is now marked by a square dot. When working with 3D graphics, these nodes are called vertices. A vertex (to use the singular) is simply a point in 3D space. A cube has eight vertices, and if you join these together you end up with 12 edges, and these form six faces. Vertices, edges and faces are fundamenta­l to how a 3D object (a mesh) is stored in Blender.

Edit mode starts off in Vertex Selection mode. Click the Select Box icon on the toolbar and then try selecting one of the corners of the cube (a vertex). Now select the Move tool, and move the vertex. This will deform the cube. As you can see, Edit Mode is the primary mode in which we alter shapes by moving parts of them and adding new parts.

Undo the changes you’ve made (Ctrl+z) so that the cube looks like it did at the beginning. Next to the mode selector (that still says Edit mode) there are three icons for vertex, edge and face selection mode. Change to Face Select mode and click one of the faces of the cube. From here, you can apply the standard tools that we’ve already covered. So for example, you could move the face around, scale it or even rotate it. Give each of these a go, to really mess up the cube and to become accustomed to using these tools.

Modifiers

Go to File>new>general to start from scratch, select the cube and make sure you’re in Object mode. One thing you’ll notice about the start cube is that it doesn’t look much like a real-world object. For one thing, it’s shaded in a simple way. For another, the edges are too sharp to look realistic. We can start softening it up by adding what’s called a Modifier, which is a powerful

Blender feature.

Click the wrench icon on the Properties Browser to edit the Modifier Properties for the object. Click Add Modifier and select Bevel from the list of modifiers. Change Segments to four. Lower the Amount to around 0.04m. Note that you can alter these fields by clicking the number and dragging with the mouse, as well as typing in directly or using the increase and decrease icons. You should now have an object that has bevelled edges rather than the harsh ones that we started with.

There’s a little icon of a TV within the Modifier pane and you can use this to toggle the modifier visibility on and off to gain a clearer idea of what it’s changing. This also reveals part of the beauty of the Blender modifier system: it’s non-destructiv­e. In other words, you haven’t actually changed anything when you added the Bevel modifier, it just appears different while the modifier is active. There’s an icon with four nodes in a square next to the TV icon, and that toggles whether or not the modifier is active during Edit mode. It’s sometimes easier to work with the raw, unaffected object in that mode, but it’s handy to be able to tab back to Object mode to get a better idea of what the finished object will look like.

Another way of getting a clear idea of what the Bevel modifier is doing to the mesh is to look at it in Wireframe mode. You can do this by selecting it using

one of the four circular Viewport Shading icons in the top right of the viewport.

Let’s make it look even more like a real-world object. Switch back from Wireframe mode into Solid mode again. Then right-click the cube and select Shade Smooth. You should have an object that looks like it’s made of clay, rather than a hard-edged geometric shape.

Cubes cubed

You’re probably seeing cubes when you close your eyes by now, and we’ll move on from them soon, we promise! However, add another cube to the scene first. To do this, select Add>mesh>cube from the menu bar (or press Shift+a). If you haven’t moved your first cube, the new one will now be inside the existing one. No problem – use the Move tool to move the new cube out of the way. However, you’ll need to let it overlap a little bit because we’re going to use it to cut a chunk out of the first cube. Make sure it’s moved up a bit as well to show the full effect.

Once you have the cubes overlappin­g, select the original cube and add the Boolean modifier to it. In the Boolean modifier properties click the Difference button. Then click the Object field and select the other cube (probably called something like Cube.001, which is the only other object in the scene).

We’ve got a problem now because, as modifiers are non-destructiv­e, we can’t move the cutting cube out of the way. To get around this, make the change permanent by clicking the down arrow (next to the camera icon in the Bevel Modifier panel) and click Apply. Now, if you move the cubes apart, you can see that you’ve cut a chunk out of one of them. Remember, you add the boolean modifier to the object that you want to affect. You might want to have a play around with the Intersect and Union buttons to see the effects that they produce compared to Difference.

Note that we now have two objects in the scene, if we go into Edit mode, we can only edit the currently selected object. That’s part of the beauty of Edit Mode because you can’t affect an object that you’re not working on.

From cube to cylinder?

Let’s add a different type of object to the scene. Start again with a new scene as before and delete the starting cube by clicking it and pressing X. Go to Add> Mesh> Cylinder, and don’t click anything else. This is easy to miss, but in the bottom left-hand side of the viewport there’s a pop-up menu that’s collapsed. In this case, it

has the words Add Cylinder on it, and we can only use it when first adding a new mesh. Press the little triangle next to those words to open the menu up. Change the depth from 2m to 3m. We’ll leave everything else as it is this time, but as you can appreciate, it’s complicate­d to change the number sides of the object at a later date.

Again, our object lacks a realistic look because it only has 32 sides to it, but once again, we can bevel it and shade it. To make it look more realistic, we’ll add the Bevel modifier, as we did with the cube example earlier on. An Amount of 0.01m is about right for the look we’re going for with three Segments.

Simply bevelling the edges doesn’t solve the problem of there not being enough faces, so add the Subdivisio­n Surface modifier. This subdivides faces into smaller faces, making the object more complex and easier to smooth, and this should be apparent if you look around the top edge of the cylinder. However, the faces on the sides of the cylinder are still obvious for some reason. What we need to do is to go back to the Bevel modifier. As it stands, it’s trying to bevel the edges between the side faces, which we don’t want. So, on the Bevel modifier panel, go to Limit Method and select Angle. Immediatel­y, we should have smoothly shaded sides when we select Smooth Shading by right clicking the cylinder.

Try putting a floor underneath your object. Add a Plane Mesh (Add>mesh>plane) to the scene and use the Move tool to manoeuvre it under the cylinder. Go to the Object Properties tab (right-hand panel) and change the X and Y scale of the plane to about 10 each.

Vary your materials

Either stick with the cylinder you have from the last section, or create a new one from scratch for the next part. Up until now, we’ve been working in the ‘solid’ shading mode which gives everything a slightly reflective putty-like appearance. If we want to change the characteri­stics of the surface of an object, such as changing the colour or adding a texture, we need to create and assign a ‘material’ to it.

Switch to the Material Preview mode by locating and clicking the icon next to the Wireframe and Solid modes that we’ve already used. You’ll see that the object that we have looks bright white because it doesn’t have a material assigned to it yet. To do so, select the object and then select the Material Properties tab on the Properties Browser. On this editor, click the +New button to add a new material. Once you’ve done this, you can colour an object by simply clicking the white area next to the Base Color field. This pops up a standard colour selector. Sure enough, when you change this, the colour of the object will change to match it.

Without leaving the Material tab, click the little yellow dot that’s part of the Base Color field and select Checker Texture. This, as you might have guessed, assigns a checkerboa­rd texture, much loved in computer graphics rendering. You can choose the two colours used by making use of Color1 and Color2 fields, and you can remove the effect by clicking the yellow dot of the Base Color field again and using the Link – Remove option. If you fancy a chromed metallic look to your object, choose white as your base colour and then turn the Metallic option up all of the way up. Then, bring the Roughness field down to about 0.175.

Hopefully, we’ve introduced you to the basics of modelling in along with a general introducti­on to the program as a whole. From here, you can start to explore the rest of the applicatio­n.

 ??  ??
 ??  ?? Challenge: see if you can make these shapes out of the basic cube using the tools and modifiers.
Challenge: see if you can make these shapes out of the basic cube using the tools and modifiers.
 ??  ?? Now the cube has a lovely squidgy look to it, thanks to smooth shading and bevelling
Now the cube has a lovely squidgy look to it, thanks to smooth shading and bevelling
 ??  ?? Moving an individual vertex of a shape in Edit Mode, in Wireframe shading mode for clarity.
Moving an individual vertex of a shape in Edit Mode, in Wireframe shading mode for clarity.
 ??  ?? Plain, bevelled and smoothed, metallic material shown at the front row of cylinders. Behind them are edited vertices and the wireframe modifier.
Plain, bevelled and smoothed, metallic material shown at the front row of cylinders. Behind them are edited vertices and the wireframe modifier.
 ??  ?? Chopping into one cube with another cube. It’s cubicide!
Chopping into one cube with another cube. It’s cubicide!

Newspapers in English

Newspapers from Australia