Notifications
Clear all

[Closed] How to clear scenematerials buffer~

hello guys!~

How to clear scenematerials buffer~ sometime there have a lot of materials unused by objects… so how to clear it ??

3 Replies
2 Replies
(@denist)
Joined: 11 months ago

Posts: 0

Here is Bobo’s solution and it works for me:

save the file (saveMaxFile()) or save nodes (saveNodes())

(@bobo)
Joined: 11 months ago

Posts: 0

To expand on this, the scenematerials library gets updated internally on file operations (because it is slow). To avoid the long wait when saving a large scene, using
saveNodes #() someTempFile
should be the fastest solution – it saves an empty file without any objects, but still triggers the update of the scene materials of the current scene…

I think it’s read only so nope. you could collect all the scene objects materials into your own scene material library or array quite easily.