Re-Use vs. Append - Lots of waste

Hi.

I am going to reuse a Blender project from a couple years ago, back when I was young and dumb. [it’s 2.79]

What I have realized is… that even though you delete things (like entire scene copies), the objects remain in the .blend file.

The “old” .blend file is 405 MB.

Obviously, if I do a “Save As…” I still have 405 MB.

But, if I append the items that I know I need into a new project, it’s only 65 MB.

So, 3 questions…

  1. Should I just not worry about it and carry on?

  2. Has anyone ever seen or created a “Project Cleaner”, to rid the world of these un-needed objects?

  3. If I was to write some Python code, what command would permanently remove objects?

I intend to use 2.79.

Thanks,
Cal

After deleting your stuff, go to “file”, “clean up” and “purge all” several times. That cleans al unused data you still have in your file.

Do it several times cause it will first clean objects, then materials, then textures… After there’s nothing else to clean up you will see a message at the bottom of the screen saying that’s nothing else to clean.

This does not clean objects that are in the file but not in any scene or view layer.

Well it cleans objects that have been deleted. If you delete a collection or a scene you still can see the objects selecting “Blender file” on the outliner screen and delete them from there if they are still in the file and then clean up.

The outliner is a very handy way of managing your file if you think a bit out of the box and select it’s many other options available.

Sorry, I’m in 2.79, mate… but thanks for the 2.8x knowledge!

Is there any reason you still work with blender 2.79?

Yes, there is.

Well, sadly I don’t think developers are really interested in creating tools to work in an outdated version of blender. So I don’t think you are going to find a cleaner for your files, unless there is one made already that I am not aware of.

All righty then…, thanks for your input.

I’ve been trying to clean up some 2.79 and older files recently as well.

It seems deleting a scene and having objects left over is similar to deleting an object and having materials and meshes left over.

But in the case of materials and meshes they are correctly added to the “orphaned data” category and “purging” orphaned data does get rid of those.

But when you have an object with no scene, you can’t delete that object and thereby cannot delete its meshes or materials either.

You can drag an object from the objects list to a scene and it will appear in the scene in the 3d viewport (but it will not appear in the regular outliner set to View Layer mode) and you can select it in the viewport and delete it BUT IT WILL NOT actually delete the object from the file. The object will remain in the Objects list.

If you drag and drop from the objects list to the 3d viewport it will create a duplicate object so deleting that will not delete the original either.

You can drag the object from the Objects list to a Scene Collection under the Scenes list and then it will appear in both the 3d viewport AND the regular outliner. But when you delete this from the 3d viewport IT STILL DOES NOT DELETE THE OBJECT from the objects list.

You have to be sure to delete any orphan Collections from the scene you deleted first and then you’ll be able to delete the objects that were in that scene. You do that by right-clicking the collection in the outliner and … wait a minute… if I delete a collection that is not a part of any existing scenes, it seems to delete all the objects in it along with it. If I delete a collection that is a part of scene, only the collection gets deleted, the objects remain. I’m confused now. Anyway, that kind of works I guess.

update… and i just now created a scenario where orphan objects exist while there are not collections anywhere in the file … but it also seems that right clicking an orphan object and pressing delete does get rid of it.

By the way, i just have seen that in the 2.79 version of the outliner you can also see the content of your Blender file.


Maybe you can clean the stuff from there.

The outliner also shows orphaned data and you can delete them there too.

AND LOOK, there’s a button saying PURGE ALL THERE!

WOW! Thanks so much. Hopefully Calandro also learns from this.

Maybe I will pose the question to the Python group… “Open a file. Clean a file. Save a file”?

Will back-burner this issue and carry on with my HUGE .blend file “Save As…”. Oh well.

Cal

Well, I don’t really know what is to learn and what needs to be requested on features that Blender already provides since long ago.

Yep. Saw that too. Did not find anything useful.

Ok then… I never had a problem to clean mine. Maybe I am doing it the wrong way…

Just tested it right now and it works perfectly, but you know…

2.79?

If so, how?

Try this in 2.79…

Start a new project, select “Append” and open a file that has multiple (full copy) scenes, and notice all of the copies of objects there are.

Then. Go back to the original file, and “clean” it - remove all but 1 of the scenes.

Start another new project, select “Append” and open the “cleaned”
version. I think that all of the objects still exist.

Might be wrong… but…

I will try.