SOG integration for WebGL

Hi!
I read the article about SOG and I am amazed! I have my own separate project on pure WebGL (without Playcanvas) and would like to integrate Gaussians in this format there.

Could you give, as far as possible, step-by-step instructions on how I can integrate this format? First of all, a parser, and maybe some recommendations for rendering.

Thanks

See the SOG reading code in SplatTransform:

Thank you very much @will
I will look into this in more detail

1 Like

As far as I understand, this file is responsible for reading the sog-file on the server for further transfer to the browser.
And where can I find the parser and shaders for the received data for the browser?

It’s all here: GitHub - playcanvas/engine: Powerful web graphics runtime built on WebGL, WebGPU, WebXR and glTF
shaders specifically: engine/src/scene/shader-lib/glsl/chunks/gsplat at main · playcanvas/engine · GitHub

but we support multiple formats and features, so this is not a single shader you can look at but a collection of parts that we put together.

most of other code is here:

but also elsewhere I’m sure

Got it, I’ll continue diving deeper. Thank you so much for your help :raised_hands:

1 Like

Hi again :wave:

I have almost fully implemented the SOG functionality in my project, but there is one strange visual bug that only appears in VR with multiview (Meta Quest 3) and Android tablets.


It seems that some of the splats are much narrower. Do you have any suggestions why this might be? Maybe it is some problem with the workbuffer and rendering on the FBO in each frame? I use the shaders from the playcanvas, with minimal changes for working with multiview (connecting several cameras instead of one).

On PCs and headsets without multiview, everything looks correct.

It could be related to the viewport uniform - with multiview, the viewport is typically half-width. Otherwise not sure.