Chapter 21
IN THIS CHAPTER
Understanding the basics of modeling in 3D
Accessing modeling tools
Specifying coordinates in 3D
Managing user coordinate systems
Changing the current working plane
Navigating in three dimensions
Applying visual styles
The addition of the Z coordinate releases your design work in AutoCAD from the planar world of two dimensions into a much more lifelike three-dimensional space. AutoCAD’s 3D capabilities have grown by leaps and bounds since AutoCAD 2007 was released with its souped-up 3D engine. Not only have the AutoCAD model creation and editing tools advanced, but it is now also a dab hand at visualization and rendering. You can view 3D models from any angle or slice through them to see what they look like inside. And finally, because the world of technical drawing is still a two-dimensional one, you can use AutoCAD’s viewing options to generate 2D drawing views from 3D models.
If you’re an AutoCAD LT user, just sit out most of this chapter and the next two. One of the major areas where AutoCAD LT differs from regular AutoCAD is in its extremely limited 3D functionality. Even viewing 3D models is much more difficult than necessary in AutoCAD LT. Those users can acquire nearly all the 3D viewing capabilities of the full version of AutoCAD, but you need a separate free program to do so. Just go to www.autodesk.com/products/dwg/viewers
and download DWG Trueview.
This chapter takes a look at some of the tools available in AutoCAD’s 3D Modeling workspace and introduces you to many of the general concepts of creating 3D objects. You also discover how to look at your model from different viewpoints, and how to change the way it appears onscreen.
Here are the three basic types of 3D computer models:
Surface: Consists of infinitely thin skins that stretch from edge to edge of a model. AutoCAD can create two types of surfaces, and hence the 3.5 reference in the section heading.
Due to space limitations, I don’t cover either type of surface modeling in this book.
Solid: Has edges, surfaces, and mass. It’s a true 3D model, so you can do interference checking between them to make sure that the parts of an assembly will fit together properly. You can also find the surface area, volume, center of gravity, and moments of inertia of 3D models. Unfortunately, AutoCAD always assumes that the material has a density of 1. If your real-life part will be made from something other than water, you need to multiply the mass values by a suitable conversion factor, depending on the actual material being used.
AutoCAD has several commands related to applying materials to solids, but they affect only the appearance and not the density.
Although surface and solid models are created and modified differently, the 3D objects that make up the models are made up of the same subobjects. The subobjects that a 3D object is made up of are
Figure 21-1 shows a simple 3D object (a six-sided cubic shape created with the AutoCAD BOX command) and its subobjects.
AutoCAD includes a plethora of tools for creating, editing, viewing, and visualizing 3D models. You can find the most commonly used tools for 3D modeling on the 3D Modeling workspace’s Ribbon.
AutoCAD comes with two 3D workspaces: 3D Modeling and 3D Basics. I suppose the idea is that if you’re new to 3D, you get your feet wet with the 3D Basics workspace and then graduate to the 3D Modeling workspace after you gain some experience. Personally, I think that the 3D Basics workspace is a waste of time; my preference is to have the whole enchilada available from the get-go. In this book, I work exclusively with the 3D Modeling workspace.
AutoCAD’s 3D environment is a lot like its 2D version, with important differences. You should be aware of the following program settings and elements:
UCS icon: When you're working in 3D, the UCS icon shows the orientation of the current X,Y plane and the direction of the Z-axis. For information on using the UCS icon, see “Changing Planes,” later in this chapter.
Before AutoCAD 2012, the UCS icon merely showed you the orientation of the X-, Y-, and Z-axes. If you used the UCS command to set a new UCS, the icon reoriented accordingly. Starting in AutoCAD 2012, the selectable UCS icon is in the driver’s seat in that you can directly manipulate the icon to change the UCS.
When you start AutoCAD for the first time after installing it, the program assesses your computer’s graphics card and — if it’s up to the task — enables hardware acceleration. With hardware acceleration, you can change the view of your model — even models with lighting and applied materials — in real time, with no deterioration in quality. Hardware acceleration also boosts the overall visual quality of drawing objects as well as regeneration performance.
Autodesk tests a wide range of cards and drivers with each new release. To find out whether your graphics card is supported for AutoCAD, check out the graphics hardware list online at http://usa.autodesk.com/adsk/servlet/syscert?siteID=123112&id=18844534
.
If your graphics card is unsupported, you may lose some or all of the shading and rendering options such as shadows, reflections, transparency, and refraction. On the other hand, current generic graphics hardware is often acceptable unless you are doing heavy-duty photorealistic renderings of things such as complex machinery or highly detailed architectural models.
In any case, if AutoCAD automatically turns on hardware acceleration, you are probably good to go.
If you’re new to the 3D game and you’ve been working in 2D until now, you need to do a couple of things before you can start a new 3D model in AutoCAD: You have to change the workspace, and then you have to open a new file by using a 3D template. The following steps explain how:
Click the Workspace Switching button on the status bar and then choose 3D Modeling.
Toolbars, palettes, and Ribbon panels flash on and off, and soon AutoCAD settles down to display the Ribbon, as configured for the 3D Modeling workspace with a few additional panels.
Click the Application button and choose New; then click Drawing.
The Select Template dialog box appears.
Choose acad3d.dwt
if you’re working in Imperial units or acadiso3d.dwt
if you’re working in metric. Click Open.
A 3D modeling space appears (see Figure 21-2) where, rather than look straight down at the drawing area, you look at it at an angle from above.
You can access most of the AutoCAD 3D modeling tools from the Ribbon and 3D-related palettes. The following list introduces you to the Ribbon tabs and palettes available in the 3D Modeling workspace. Note that not all items in this list are visible in Figure 21-2 and that this list omits some items that aren't unique to 3D.
The following list describes what you can do with the palettes found on the View tab of the Ribbon:
Materials Editor: Apply, create, and modify materials in the current model. Chapter 23 introduces you to materials.
Applying materials in AutoCAD affects only the appearance and not the density or other properties.
The following palettes are found on the Render tab of the Ribbon:
So far in this book, I’ve explained how to work with X and Y coordinates only. X and Y coordinates by themselves define a two-dimensional plane known (logically enough) as the X,Y plane.
In this chapter and in Chapters 22 and 23, you supply a third value — a Z coordinate — to locate geometry above or below the X,Y plane. You use the same methods to specify Cartesian (X,Y,Z) coordinates as the ones I set out in Chapters 1 and 8. You just add a comma and another number. The following techniques can be used to specify points in 3D:
I introduce you to 2D coordinate entry in Chapter 8. To recap, the input formats are
Although you can use these 2D coordinate input methods in 3D, you usually have to give AutoCAD just a little more information when you want to work in three dimensions. You can use absolute or relative Cartesian coordinates by simply adding a Z coordinate to the end. In addition, there are two 3D–only coordinate formats, both based on 2D polar coordinates. You can enter 3D coordinates with the following methods:
Coordinate entry (as described in the preceding section) is fine if you already know the coordinate values or distances in 3D space where you want to locate your points. Often, however, you may need to derive 3D points from existing geometry without knowing those exact values. Using point filters, you can locate new points based on existing points. You can use point filters to construct 2D and 3D coordinates.
When AutoCAD prompts you to specify a point, you can either enter point filter values at the command line or bring up the right-click menu and choose a filter option from the Point Filters submenu. After selecting a point filter option, specify a point to filter out part of the coordinate value and then enter the requested value. For example, use the -X,Y filter to enter your own Z coordinate value after specifying a point on the current working plane.
Object snaps allow you to accurately specify points on existing objects in a 3D model. You can use endpoints, midpoints, and center object snaps on 3D objects, but AutoCAD also provides a set of object snaps specific to 3D modeling.
Three-dimensional object snaps allow you to specify points on 3D objects that regular object snaps don’t recognize, such as a vertex or the center of a face. You enable 3D object snaps by clicking the 3D Object Snap button on the status bar. Right-click the 3D Object Snap button and choose the running 3D object snap modes that you want to use.
Object snap tracking allows you to calculate points that are not on an object by using object snap points on existing objects. When working in 3D, you can track points on not only the current X,Y plane but also along the Z-axis. While tracking points along the Z-axis, AutoCAD provides feedback in the form of a tooltip that lets you know you’re moving along the Z-axis in the positive or negative direction.
Come fly with us while I explain changing planes in AutoCAD. Just step through this metal detector over here while I x-ray your bags.
Okay, it’s not that kind of plane. This section covers using the user coordinate system (UCS) to control the current working (or X,Y) plane. The UCS icon, displayed either at the lower-left corner of the drawing window or at the origin (0,0,0), shows you the orientation of the current work plane and the positive direction of the Z-axis. I cover UCSs in Chapter 8.
By default, the UCS icon is displayed in both 2D and 3D views. You can lose your bearings pretty easily when working in 3D, and I strongly recommend that you keep the UCS icon in your sights at all times. You can toggle it on or off by clicking the UCS Icon icon (yes, the UCS icon is labeled “UCS Icon”) in the Viewport Tools panel of the View tab on the Ribbon.
In previous releases, the UCS icon was merely a graphical indicator of the current coordinate system. If you set a new UCS in model space, the UCS icon adjusted to show you the orientation of the new X,Y plane and Z-axis. In other words, the UCS icon was driven by the current coordinate system. Beginning with AutoCAD 2012, the UCS icon moved across to the driver’s seat! You can select the UCS icon and see new multifunction grips that allow you to set a new UCS by dragging the grips on the origin and the legs of the icon. There’s also a right-click menu. You can enable or disable UCS icon selectability on the Settings tab of the UCS dialog box. Type UCSMAN and press Enter to open it. In the next section, I show you how to create a new UCS by selecting and manipulating the UCS icon.
Every drawing you create uses the World Coordinate System (WCS), but when working in 3D, you need to create additional work planes. For example, you might want to drill a hole on the angled face of a wedge. User coordinate systems (UCSs) are necessary when you need to draw objects on work planes other than the WCS. In the real world, think of latitude and longitude as the WCS; street naming, house numbering, and hotel room numbers are all local systems and are equivalent to UCSs. Traditional UCSs are static; create one, and it stays current until you change it. By default, such coordinate systems are unnamed, but you can assign a name and save it for future use.
A couple of releases back, AutoCAD introduced Dynamic UCSs. Because dynamic is the opposite of static, what you get is a temporary coordinate system that changes as you move the mouse pointer over different planar faces of a 3D object. Click the Allow/Disallow Dynamic UCS button on the status bar, or press the F6 key to toggle Dynamic UCS on and off.
The UCS command offers ten options to help you define a new UCS. Access the UCS command options from the Coordinates panels on either the View tab or Home tab of the Ribbon.
After you select one of these UCS options from the Ribbon, follow the command prompts at the command line or the Dynamic Input prompt.
For more information on all the UCS command’s options, refer to AutoCAD’s online Help system.
The more UCSs in your drawing, the more you need help managing them. AutoCAD offers a handy-dandy UCS dialog box for doing just that. Open it by clicking the dialog box launcher (the little arrow at the right end of the panel label) on the Coordinates panel of the View tab or Home tab, or simply type UCSMAN and press Enter. The three tabs in the UCS dialog box are
After you define a UCS that you think you might want to use again, you can save it in the UCS dialog box. I explain how in the following steps, which you begin by creating a solid box:
Start a new 3D drawing by selecting acad3d.dwt
(or acadiso3d.dwt
for the metric crowd) for the template, and ensure that the 3D Modeling workspace is current.
Refer to the steps in the “Entering the third dimension” section, earlier in this chapter, if you need a refresher.
On the Modeling panel of the Home tab, click Box.
AutoCAD prompts you:
Specify first corner or [Center]:
Type 0,0,0 and then press Enter.
AutoCAD anchors the first corner of the box at the origin of the WCS and prompts:
Specify other corner or [Cube/Length]:
Drag the cursor away from the first corner and click a point to set the length and width of the box.
Exact distances don’t matter in this example. AutoCAD prompts you:
Specify height or [2Point]:
Drag the cursor upward from the second corner and click to set the height of the box.
AutoCAD creates the 3D box and exits the command.
Then you define the UCS by following these steps:
Move the cursor over the UCS icon.
The UCS icon shows the orientation of the world coordinate system. As you move the cursor over the icon, it turns a greenish-gold color, indicating that it can be selected.
Click to select the UCS icon.
A square, multifunction grip appears at the origin, and round, multifunction grips appear at the ends of the icon’s legs.
Move the cursor over each multifunction grip and look at the grip menus.
Hovering over one of the round grips at the end of a leg lets you choose between realigning the selected axis and rotating the UCS around one of the unselected axes. Hovering the mouse pointer over the origin grip lets you move the UCS origin to a new location and either keep the current alignment of the X- and Y-axes or realign them. The third grip option, World, restores the WCS.
Now you use the UCS icon’s multifunction grips to set a new UCS.
Click the UCS icon to select it, and then move the cursor over the square, multifunction grip at the origin.
The cursor jumps to the origin, and the grip menu appears.
From the grip menu, choose Move and Align.
AutoCAD prompts you:
** MOVE AND ALIGN **
Specify origin point or align to face, surface, or mesh:
Move the cursor to a different corner of the box, and when the UCS icon origin is over the corner, click to set the new origin.
If you want, you can drag the round grips on the axes to realign the new UCS.
Finally, you have to save it. Follow these steps:
On the Coordinates panel of the Home tab, choose UCS, Named UCS.
AutoCAD displays the UCS dialog box.
With the Named UCSs tab current, select Unnamed in the UCSs list.
The new, unnamed UCS is the current UCS in the drawing and is listed at the top of the list.
Right-click Unnamed and choose Rename from the shortcut menu.
An in-place editor is displayed that allows you to rename the UCS.
Type a name for the new UCS and press Enter.
The Unnamed UCS is renamed (see Figure 21-3).
Click OK.
The UCS dialog box closes, and the new UCS is saved in the drawing.
To switch back and forth between the two UCSs, simply select the one you want to use from the Coordinates panel:
A named UCS allows you to work on different work planes, but it can take a bit of effort to set up, and that can distract you when you’re focused on 3D modeling. With Dynamic UCS, you can focus on modeling, not on creating a UCS. To enable or disable the Dynamic UCS feature, click the Dynamic UCS button on the status bar.
Figure 21-4 shows an example of drawing a circle on the side of a 3D solid. When Dynamic UCS is enabled, AutoCAD highlights the face of the 3D solid that the UCS will be aligned with. Click over the face to align the UCS with the face, and then finish the command. The circle is aligned with the face of the 3D solid, and the previous UCS is then restored.
If you’re new to 3D in AutoCAD, you may be wondering how to look at whatever it is you’re modeling from whatever angle you desire.
The easiest way to switch to viewing from a different direction is to use ViewCube (shown in Figure 21-5) to switch to a standard orthographic 3D view or an isometric view.
Before I explain the ViewCube, however, here’s a bit of background information for you.
The six orthographic and four isometric views work well for showing 3D models of common objects such as mechanical components and buildings. You can also change to plan view, which is a top-down view of either the world coordinate system or a UCS.
AutoCAD LT has limited 3D viewing capabilities. The same preset views are in both AutoCAD and AutoCAD LT, and you can also use the Viewpoint Presets dialog box (ddVPoint command) in which you set a viewing position by specifying angles in and from the X,Y plane. Finally, there’s the really ugly command-line-only VPOINT command, left over from last-millennium releases. Man, that one’s so ugly that it’s not even on the Ribbon!
Preset views are fine for many 3D modeling tasks, but if you really want to have fun, 3DOrbit (not in AutoCAD LT) is your ticket to it. Orbiting a 3D model in AutoCAD is similar in concept to orbiting Earth in a satellite, only a lot cheaper. The three orbiter modes are Constrained, Free, and Continuous.
Free Orbit displays an arcball on the screen in the form of a circle representing a sphere around the object. You click various places inside, outside, and on the arcball and then drag to change the 3D view. The idea is that you’re spinning an imaginary sphere containing the model. As you drag the cursor, AutoCAD updates the screen dynamically.
Constrained mode is pretty much like Free mode with training wheels in that you can orbit only horizontally and vertically.
Continuous mode lets you leave a mode spinning continuously. To change the orbit direction and speed, simply click-drag-release the mouse. The model orbits in the direction defined by the mouse motion, and the orbit speed is determined by how fast the mouse was moving when you released its button.
You might also want to experiment with different projection modes:
If you manage to 3DOrbit out of control and can no longer see the model, right-click to display the 3DOrbit shortcut menu and then choose Zoom Extents. The Zoom, Pan, and Preset Views options offer other ways to get the model back in your sights.
With so much talk about hybrid devices these days, Autodesk decided to create its own, in the form of the ViewCube (not in AutoCAD LT). The interactive ViewCube tool (see Figure 21-6) provides visual feedback about the current viewpoint, and allows you to set a preset view current or orbit the model, restore a named UCS, and define and restore the Home view of a model.
To change the view of the model by using the ViewCube, you can do one of the following:
Home view is a special view you can define so that you have a known reference view in the model. That way, if you lose your bearings, you always have a way to get back home. You can restore Home view from the ViewCube or from the SteeringWheels right-click menus.
SteeringWheels act as a kind of navigation hub that allows you to access several different 2D and 3D navigation tools from a single user interface. AutoCAD LT includes only the 2D Navigation wheel. AutoCAD (the full version) comes with the 2D Navigation wheel and three other wheels that are designed to be used with 3D modeling. The three additional wheels are
When a wheel is active, move the cursor over the wedge that contains the tool you want to use. For many of the tools, you either click over the tool or click and drag to use the tool. Some tools support alternative versions of themselves when you press and hold the Shift key. To get an idea of what each tool does, hover the cursor over the tool to display a tooltip message. To read more about each of the wheels and the tools on them, see AutoCAD’s online Help system. To display the help that's specific to the wheels, right-click when a wheel is displayed and choose Help from the shortcut menu.
It really doesn’t seem like that long ago when the only way to view 3D models was in Wireframe mode, but the last several releases have dramatically improved AutoCAD’s visualization capabilities. It now has almost a dozen different display modes, called visual styles, that you can set with the click of a drop-down menu. Figure 21-7 shows the default visual styles, and you can add your own in the Visual Styles Manager palette.
Visual styles are collections of settings that determine how a 3D model is displayed.
AutoCAD’s preconfigured visual styles are only the beginning. You can modify any of the styles and create new ones in the Visual Styles Manager palette (refer to Figure 21-8).
To display the Visual Styles Manager, click the dialog box launcher (the little arrow at the right end of the panel label) on the Visual Styles panel of the View tab, or enter VisualStyles or VSM at the command line and press Enter.
The different visual styles presented in this chapter are good for helping you navigate while you’re working on a 3D model. But when it comes time to impress a client, you need to use photo-realistic rendering, which I discuss in Chapter 23.
18.191.235.62