1
$\begingroup$

Blender 2.92.0.

I have three files: source.blend, destination.blend, and test_image.png.

source.blend consists of a single cube with a single material on it. The material has an Image Texture node which reads test_image.png from the local directory. This all works as expected.

destination.blend consists of a single cube. After File ⭢ Link... and selecting the material in source.blend, the material is applied properly to the cube. This all works as expected.

Now, if within destination.blend, I select File ⭢ External Data ⭢ Pack All into .blend, I get the message "No new files have been packed." If I move destination.blend out of the directory, so that it can no longer reference source.blend, the material is no longer available.

The documentation suggests that only some kinds of assets can be packed into a .blend, but I would imagine materials should be on that list, no? Even if I don't link the material, but instead just create a new material with the Image Texture set to the PNG image, pack everything, and move destination.blend into an isolated directory, the image isn't packed either.

What am I missing?

Similar Questions: Packing Texture Files In a Single Blend File does not answer the question. The accepted answer simply says to use File ⭢ External Data ⭢ Pack All into .blend, which as I described doesn't work. In the comments under the accepted answer, the asker points out that as of 2.92, "Packing movies, image sequences or tiled images not supported". But the image in question is not a movie, image sequence or a tiled image, and besides that, I've also demonstrated that materials are not being packed as well.

I've attached the files I created. You can create any valid PNG image as test_image.png within the same directory.

$\endgroup$

2 Answers 2

3
$\begingroup$

You're confusing two separate concepts.

  • Packing is for external media files. So .png image textures, .txt texts and .py scripts, .ttf fonts, etc. can be packed. Packing embeds those entire files as binary blobs in the current .blend file.

  • Linking is for specific ID data blocks from another .blend file. So Objects, Meshes, Armatures, Actions, Materials, Curves, Scenes, Cameras, Worlds, etc. can be linked. These linked data blocks can't be "packed" because there isn't anything to pack— They're read from part of the library .blend file, so they don't correspond to any single, whole external file that can be embedded in your current .blend file.

You probably want to use "Make Local", which will basically copy the specific data that's been linked from the library .blend file into the current .blend file. You can also click on the little number or chain icon next to the ID data block selector field, which will make a copy of it in your file, although you might then have to switch every user of that data block to the new copy separately.

$\endgroup$
4
  • $\begingroup$ So Pack All External Data only refers to external media on the filesystem? That's... Okay. Well anyway. What is the proper way to have all of the assets of linked files self-contained in the file referencing them? $\endgroup$ Jul 1, 2021 at 2:27
  • 2
    $\begingroup$ @wherezyurheadat I think "Make Local" —> "All", followed by "Pack All" should do it. (Note: Originally had error in answer, said "Make Single User" instead— Might also work, but will create unnecessary duplicate data.) The order matters because you want the linked images to be in the file for packing. Could also "Append" instead of "Link" from the start, depending on workflow. Set your Outliner to "Blender File" to see what data is currently linked from library files at the bottom, or "Data API" to check for the value of "Packed File(s)" for all images. $\endgroup$
    – Will Chen
    Jul 1, 2021 at 2:43
  • 1
    $\begingroup$ @wherezyurheadat This will get linked .blend/"DNA" data, images and fonts, but not video clips IIRC (understandably, IMO). Run this code in your Python console panel to get a list of any media files that haven't been packed: [d for a in dir(bpy.data) for t in [getattr(bpy.data, a, [])] if hasattr(t, '__iter__') for d in t if not getattr(d, 'packed_file', True)] $\endgroup$
    – Will Chen
    Jul 1, 2021 at 2:52
  • $\begingroup$ Thank you all very much! $\endgroup$ Jul 1, 2021 at 3:15
0
$\begingroup$

Materials don't pack. Or, maybe, they're always packed. You could think about it either way.

Images pack. But I'd suspect that any issues you have are related to the fact that you're linking data from a different file. No matter what you do, linked data is going to use the info from the file from which you linked it. There's nothing to pack, because the image texture isn't being referenced by the file you're in; it's being referenced by the file you're linking.

If you want to pack stuff, edit stuff, unlink the objects (+ mats.) You cam use the "make single user" menu for that, 'u' in 3D viewport object mode for me, which I think of as "unlink." If you want to see the file size change, of the linked file, pack/unpack stuff in the source of the linked data.

$\endgroup$
4
  • $\begingroup$ ...They killed the "U" hotkey around 2.8, I think. I have to search in the F3 menu for "Make Single User" nowadays. $\endgroup$
    – Will Chen
    Jun 30, 2021 at 23:29
  • 1
    $\begingroup$ @WillChen Pre-2.8 interface FTW :) Only thing I miss is 3d viewport f2 renaming.... $\endgroup$
    – Nathan
    Jul 1, 2021 at 1:53
  • $\begingroup$ 2.49 had a CTRL+SHIFT+P BI render preview popup that only rendered part of the screen... Quite nice compared to the current rendered view mode, with limited processing power. I still have muscle memory for F1 and F2 to save/open.... I think I actually go through the "File" menu these days; I'll use the normal shortcuts elsewhere, but they just don't feel right in Blender. $\endgroup$
    – Will Chen
    Jul 1, 2021 at 3:24
  • $\begingroup$ Huh. I didn't know that was a thing. I used the old F2 "Save as" so much that it seemed kinda sacred lol. $\endgroup$
    – Will Chen
    Sep 20, 2021 at 15:56

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .