.
Читать онлайн книгу.throughout both Blender’s interface and its internal structure, so understanding how they work and how you can take advantage of them goes a long way to understanding Blender itself. Nearly every critical element in Blender is stored in a type of datablock, from workspaces and scenes to objects and animations.
Not only is a datablock a handy way to store information, but it also allows Blender to treat this information like a database. In particular, you can link datablocks and let them share information. As an example, say that you’ve created an excellent wood material, and you want to have two objects — a table and a chair — look like they’re both made of the same wood. Well, rather than re-create that exact same material for each object, you can simply link both object datablocks to the same material datablock. Your computer uses less memory, and, more importantly, you have less work to do. And because datablocks are used throughout Blender, this same concept works in all kinds of situations: sharing textures between materials, sharing particle systems between objects, and even sharing worlds between scenes. It’s an incredibly powerful feature of Blender, and I refer to datablocks a lot throughout this book.
A second way to verify the linked status of duplicates is to look in the Object Data tab of the Properties editor. At the top of this panel, look at the top datablock field. This datablock field gives the name of the mesh datablock that your active object is using. In this case, that mesh datablock is named, appropriately, Suzanne. To the right of the name is the number of objects linked to this datablock. In other words, this number is the count of your linked duplicates. In the case of Figure 4-9, the number is 3. If your datablock is linked to only one object, also known as having one user, then there’s no number at all. Figure 4-10 shows how this panel looks when one of the Suzannes in the previous figure is selected.
FIGURE 4-10: Three objects are sharing this datablock.
Another way to visualize linked data in Blender is to consider that Blender treats the internal structure of its.blend
files like a database. As I cover in the “Understanding Datablocks: Fundamental Elements in a Blender File” sidebar in this chapter, all datablocks in your scene — including objects, materials, and mesh data — can be linked and shared between one another. The real power comes in allowing multiple objects to share with each other. For example, you can have objects share materials, mesh data, actions, and even particle systems. And different scenes can even share objects! Taking advantage of this feature not only reduces the size of your .blend
files, but it can also seriously reduce the amount of redundant work you have to do. Figure 4-11 shows a data schematic for the previous scene involving the three linked duplicates of Suzanne. You can see how the datablocks in that scene relate to one another.
FIGURE 4-11: A data schematic of linked Suzannes.
So say that you’ve been using Blender for a while without knowing about linked duplicates, and your .blend
file is rife with redundant mesh data. Is there a way to get rid of those regular duplicates and make them linked duplicates? Of course! Follow these steps:
1 Select all the objects that you want to share the same data.Use any of the selection tools available to you (Box, Circle, Lasso, and Shift+click). All the objects must be of the same type, so you can’t have a mesh object and a curve object share the same datablock.
2 With each desired duplicate selected, add to your selection (Shift+click) the object with the datablock that you want to share with the others.This step makes that last-selected object the active object.
3 Choose Object ⇒ Make Links from the 3D Viewport’s header menu or press Ctrl+L to open the Make Links menu.
4 Choose the second option from the top, Object Data.Kerplooie! All the selected objects now link to the same internal data.
Figure 4-12 shows the preceding process, using a bunch of cubes and a Suzanne object.
FIGURE 4-12: Linking cubes to Suzanne.
You probably noticed that the Make Links menu had some other interesting options. Following is a description of what each one does:
Objects to Scene: If you have multiple scenes in your .blend file, you can make those scenes share the same objects. This option reveals another menu with all the scenes in the file. By choosing a scene, the object or objects that you selected have linked duplicates created in that other scene.
Object Data: This option is the one you used in the preceding example. Object Data links the internal data — be it a mesh, a curve, a lamp, or nearly any other object — of the selected objects to the internal data of the active object. For this option to work, all the selected objects must be of the same type. This is the only option where having objects of the same type is important.
Materials: Choosing this option causes all the selected objects to share the same material settings. For more information on materials, see Chapter 8.
Animation Data: This option relates directly to animation. It’s the set of keyframes that describe the motion of an animated object, called actions. (Chapter 13 has more information on actions.) Choosing this option causes all your selected objects to share the same actions as the active object.
Collection: In the “Discovering parents, children, and collections” section of this chapter, you see how Blender allows you to organize your objects into collections. Choosing this option puts all the selected objects in the same collection.
Instance Collection: One cool thing about collections is that you can generate them as duplicated instances in a few ways. Choosing this option allows multiple objects to share the same instance collection.
Modifiers: A modifier is an operation that Blender performs on your object’s data without permanently changing that data (see Chapter 5). Modifiers allow you to have very complex models that are still manageable, while retaining the simple editability of the original data. Unlike most of the other options in the Make Links menu, this option doesn’t link the same modifier to multiple objects. What it really does is copy the modifier and its settings from one object to another. In the future, you may be able to treat modifiers as linkable datablocks, but that is not currently the case.
Fonts: This option is specific to text objects. If you want to change the font on a bunch of text objects at the same time, it can be a pretty tedious manual process. However, by choosing this option, you can quickly set the same fonts for all selected text objects.
Transfer UV Maps: UV maps (covered in Chapter 9) are used for mapping a 2D image to the surface of your 3D object. You can share UV coordinate layouts between multiple 3D objects that share the same mesh topology (objects that have the same number and connections between vertices, but not necessarily the same vertex positions).Like modifiers, this doesn’t really link datablocks; it actually copies the UV layout from one mesh to the other. If you edit the layout after that,