Export Compressed .glb leaves loads of image files as glb files next to the glb model exported

Just tried exporting a model from the scene hierarchy through the Needle right click menu > Export as glb then Export as compressed glb. Normal glb export gave me one glb model, compressed export of the glb gave me this set of files. Should those image files be deleted after conversion?

Original Post on Discord

by user 103054507105067008

No those files contain the high quality textures that are created for progressive texture loading

If I’m using that model on its own in a model viewer ie. drag/dropping that model into the viewer, what can I do about that?

by user 103054507105067008

When building a normal scene you can disable progressive textures by disabling the toggle here - but for the context menu I think you can not disable it globally
image.png

I turned off progressive loading on the original texture files but the exported compressed model still exported with separate files

by user 103054507105067008

Might be useful to have somewhere to disable that for the context menu as the exported compressed glb file is unusable on its own as a single file for model viewers

by user 103054507105067008

You mean <model-viewer> for example?

Yep, or just to ensure I have a single exported glb file I can use in my own model viewer I use internally at work

by user 103054507105067008

Even just a new context menu option to export as a single glb compressed without progressive loading would be nice :slightly_smiling_face:

by user 103054507105067008

Changed the channel name: Export Compressed .glb leaves loads of image files as glb files next to the glb model exported

by user 103054507105067008

I’ll add a new context menu item for it for now but we have to think about a better solution for the future

Thank you, that’s great for now

by user 103054507105067008

@ROBYER1 just to make that clear: if you’re exporting with the Needle/* menu items you’ll get glbs that contain Needle extensions, lightmaps, and referenced files (other GltfObjects, Prefabs, Audio, progressive Textures) will be exported alongside the file. For use in model-viewer you’d typically not want that, as not all viewers may correctly ignore the extensions they don’t understand.

Am I right to assume that all you want in this case here is “the same output as with UnityGltf but compressed / optimized with Needle’s pipeline”?

That’s correct, some way to export the glb with the compression Needle uses but as a normal file that can be used in model viewers

by user 103054507105067008