mkkellogg / GaussianSplats3D

Three.js-based implementation of 3D Gaussian splatting
MIT License
1.54k stars 199 forks source link

How to determine which Gaussian bodies are rendered first while progressive loading ? #317

Closed Linkersem closed 2 months ago

Linkersem commented 3 months ago

Hello, Thank you for your outstanding work! I would like to know, in the process of progressive loading, how to determine which Gaussian primitives are rendered or loaded first? I don't seem to find it in the code, can you please tell me the general principle and where it is in the code? Thanks for your reply!

mkkellogg commented 2 months ago

The splats are loaded in the order that they are organized in the file from which they are loaded. You can simply look at Viewer.splatMesh.getSplatCount() to get the number of splats currently loaded.

Linkersem commented 2 months ago

Thanks for the reply! can I understand that the ply file obtained from the original 3d gaussian-splating training does not do some extra operations in the loading process, but instead is the file type that has already been processed for ksplat and splat files?

mkkellogg commented 2 months ago

Right, the .ply files are the native output of the original 3DGS process. .splat (developed by Kevin Kwok) and .ksplat (developed by myself) are processed versions of those files. The order of splats in .splat depends on the software used to generate them -- Kevin's viewer will generate them, but it won't reorder the splats, while I think Super Splat optimizes the order for better cache usage. The splats in my .ksplat files are also reordered to have better cache utilization.

mkkellogg commented 2 months ago

I'll close this for now, but let me know if you have any other questions.