playcanvas / editor

Issue tracker for the PlayCanvas Editor
https://playcanvas.com/
161 stars 28 forks source link

Revisiting asset bundles #949

Open yaustar opened 1 year ago

yaustar commented 1 year ago

We have a bundle feature in the Engine and behind a feature flag on the Editor.

https://github.com/playcanvas/engine/blob/main/src/framework/bundle/bundle-registry.js

The expected format is a .tar file and decompression happens on the client after it downloads, at which point all the assets are loaded and processed.

Issues arise from this:

yaustar commented 1 year ago

I was thinking this morning that rather than tar-ing it, can we make a binary blob that is uncompressed and therefore has no decompression time. We can still rely on server/browser based gzipping to make the package smaller.

Or could we tar this in a way that has no compression (except on network delivery with gzip) and therefore is very quick to open?