huggingface / gsplat.js

JavaScript Gaussian Splatting library.
MIT License
1.26k stars 78 forks source link

working with gziped files #27

Open steam0r opened 7 months ago

steam0r commented 7 months ago

hello,

it seems that these lines rely on the content-length header being set to create an array:

https://github.com/dylanebert/gsplat.js/blob/e8a23157b565945a50132dae1a865bb363a4c934/src/loaders/Loader.ts#L15C1-L16C52

this header is not present when gzip-compression (or chunked encoding) is enabled (at least in nginx, and some configurations of apache) and thus results in Uncaught (in promise) RangeError: source array is too long.

Maybe it would be possible to create a dynamically sized array in these cases and live without having progress information?

thanks!

TravisThomp commented 4 months ago

Should be fixed now with #57