I was having a bit of trouble with slow renders so set about creating a simpler component. How you do this seems to make a huge difference in file size.
Component created & saved as a skp file - 5.4Mb. In the basic template I spotted even after purging there was an Environment Scene saved with the file. I had to set the environment to none & purge again.
Purged file saved again as a skp file - 154Kb. Huge reduction but still too big for what it should be.
Contents of .skp made into Component and exported using context menu âSave Outâ. Finished file size 20Kb.
I get the environment affecting the file size, it is definitely one to watch if you donât need that data in your SU file. I will also be using âSave Outâ whenever possible in future component exports.
Same 20Kb file size. I guess creating a component as a file and saving it, even if purged, retains some other data that might be irrelevant but canât be purged e.g. geolocation. âSave Outâ I assumes strips everything except the basic geometry.
When you add an environment to your model, there is an HDRI file that is saved into the project - that is around 4mb
Just like materials.
The Thomthom model itself has a few extra material maps in him too, so even thomthom himself is responsible for file sizes being larger.
The point I was trying to make Adam was the supplied template files already have an HDRI file saved in the project even if it isnât displayed. So as I did, you set out to create a simple component and purge everything, but the unused HDRI is still included. You have to turn on the Environment tray and select none, then purge the HDRI to get rid of that 4Mb bloat.
The supplied âVisualizationâ template files do but I donât see any of the others that contain an HDRI file. You could, and probably should, make your own default template. Then you can leave out the scale figure and his materials as well as any HDRI environment files if you want.
OK point taken, I have been so focussed on finding a millimetre template I missed the VISUALISATION clue.
I do typically use my own template, but I stand by my concerns for anyone new to SU that even though you may not display an Environment image in any Scene, they can be present and missed in the purging process.
Just for feedback I realise now what has thrown me⌠Having used the Visualisation Millimetre template and zoomed in on my component the presence of the white ground plane and having fog turned on left the Environment image both masked & off screen, so its active presence was forgotten. My lesson for today.
I looked at this, but until v2025 is more stabilized I wonât add that purge function.
To see the current issue: in v2025 add an environment, but donât use it,
then in the Ruby Console use the API method: Sketchup.active_model.environments.purge_unused
It is removed, but if you do sometime next and youâll always get a BugSplat!
Perhaps someone âin authorityâ can comment and log a report⌠@colin ?
The ...some_collection.purge_unused methods works faultlessly with all other purge-able methodsâŚ