Unit 2 Lesson 4

advertisement
Week Two Lesson Four
Boolean Operations Continued
We have looked at how Boolean operations such as the Subtract and Union tools can be
quite useful for either adding complexity or detail to simple shapes. Today we will consider the
remaining Boolean types, and wrap up the discussion of these powerful modeling tools before we
move on to tomorrow’s lesson, in which we will create another cool 3-D object utilizing the
Boolean tools we have become acquainted with.
The two Boolean tools we have not used yet are the Add and Intersect types. Although
these tools are not used as frequently as the Union and Subtract tools, they are very handy and
in some cases are about the only way to achieve a desired effect. In keeping with our philosophy
of learning through doing, we will get a close look at these tools in action. We will begin by
considering a hypothetical situation.
Let us say that we want to do an animation of a series of bullets hitting a wooden door. It
is a shot we have probably all seen before.” BAM, BAM, BAM”. We hear the gun’s report
simultaneous with the appearance of the bullet holes and flying bits of wood sent hurtling by the
bullet’s’ impact. In terms of the animation of such a shot, we need to model a few objects to
create this illusion. We will need: a solid panel which will serve as the door, a cutting tool object to
drill out the bullet holes, plugs in the shape of the bullet holes, and pieces of wood to fly out of the
holes “on impact”. Happily, Boolean functions make the modeling process a breeze. Open the
Modeler work Interface and we will get started.
1. First, we will need a door to blast. For our purposes we can use a simple box object. The
dimensions don’t need to be too exact for this demonstration so you can be fairly loose
with things. Just drag out a box object about 1m square on the width and height (in the
Back view) with a depth of about 40mm or so (in the Top or Right view).
2. Select the next empty layer and put Layer 1 into the background. Now we will create a
cutting tool that we will use to make our bullet holes. Select the Disc tool and press and
hold the “Ctrl” key (or Middle Mouse Button). while dragging to keep it nice and round.
Remember that the viewport that you begin in will determine the orientation of the disc.
Begin in the Back view and then, when you have achieved the desired radius, switch to
the Right or Top view to drag out the depth of the disc. You will need the disc to extend
beyond the edges of the box in the background so that the hole will go all the way
through. Move the disc over to the upper right center of the panel object, as we are going
to make a series of holes from left to right. To move the disc while the Disc tool is still
active, click on the cross at the center of the disc and drag it to the new location (Figure
1).
Figure 1
3. Bullet holes have a tendency to be kind of rough around the edges as wood hardly ever
splinters in a smooth, even way. It’s relatively easy to simulate a rough splintered look by
using the Drag tool located on the Modify tab’s tool menu. Select the Drag tool and
simply position the cursor over one of the edge points in the Back view and click and drag
the point to a new location. Drag out 4 or 5 random points (nothing ever breaks in an
orderly fashion). When finished your shape should, (more or less), resemble Figure 2.
Figure 2
4. Copy the contents of the layer to the clipboard. Select the next empty layer (it should be
Layer 3) and Paste the shape in there.
5. In the next empty layer (probably 4), repeat the Paste operation.
6. Now, for the objects in layers 3 and 4, use the Move tool to arrange the other hole cutting
objects so that the 3 of them (each in it’s own layer) form a line from upper left to lower
right. You can also randomly Rotate them so that there’s a bit more variation.
7. Place the cursor over the center of the object when rotating since rotation in modeler is
relative to the cursor position. If you need to have multiple layers in the background, hold
the Shift key down while clicking on the bottom halves of the layer buttons. The results
after all this should resemble Figure 3 (it doesn’t have to be too exact).
Figure 3
8. Now that we have all our cutting tools in place, it should be fairly easy to do a Boolean
subtract to create the holes. We have already discovered how to do that. Before we do,
though, we need to make some plugs that will exactly fill the holes so that the wood will
look undamaged until the moment of impact. Make a copy of each of the cutting tools,
and put each in its own separate layer, just as we did above. Now, Layers 2- 7 should
each have a drilling shape in them with 2 and 5, 3 and 6, and 4 and 7 being identical to
each other. In other words, put a copy of Layer 2 into Layer 5, a copy of Layer 3 into
Layer 6, and a copy of Layer 4 into Layer 7.
9. Now, we will make a plug for the hole to be created using the shape in Layers 2 and 5.
Select Layer 2 as the current foreground layer. Select Layer 1 as the background layer.
10. Select the Boolean tool from the tools on the Construct tab. Select Intersect as the
Operation type, and click OK to perform the operation. This operation leaves us with a
plug in the shape of the cutting tool with front and back edges that will seamlessly match
up with the door’s plane, effectively filling the pre-fabricated bullet holes until the
appropriate moment. Be sure to hit the “m” key to merge points and get rid of the junk
geometry created by the Boolean.
11. Select Layer 3 as the foreground layer. Put Layer 1 into the background and repeat the
Boolean intersect as in Step 9. Merge Points.
12. Select Layer 4 as the foreground layer. Put Layer 1 into the background and repeat the
Boolean Intersect and Merge operations one more time. Now we have all the plugs we
need for our three bullet holes.
13. It’s time to create the holes in the door now. Select Layer 1 as the foreground layer. Hold
down the “Shift” key while clicking on the bottom right of Layers 5, 6, and 7 in order to put
all three cutting tools into the background.
14. Select the Boolean tool. This time, select Subtract from the Operation types listed and
click on Ok.
15. Your door object should now have three holes in it, which exactly match the plugs we
made earlier, as in Figure 4. We can now safely Delete the cutting objects in layers 5-7.
Now it will be an easy matter to bring this object into layout and simulate its violent
demise. Save the object for later animation. Until then, hopefully you can see how using
the Boolean Intersect tool is useful for creating animating holes and such.
Figure 4
The final Boolean to discuss is the Boolean Add tool. This tool is somewhat less useful
than the others we have covered. It serves as a kind of alternative to just cutting and pasting one
object into another objects layer. The advantage it offers over the cut and paste is that shared
edges are created where the geometry overlaps. This is useful for adding detail to an internal
space, like pipes running through a room or something of that nature. It is pretty un-exciting so
that’s all we will say about that. For now, just remember that for all Boolean operations you
should always do a Merge Points afterwards to get rid of point duplicates.
Think about other cases where Boolean Intersections might come in handy. Any place
where you need both a hole cut in a shape, and a plug for the hole (until it is made in the
animation) is a great job for Boolean Intersects.
Download