babylon.quarks - v1.0.0
    Preparing search index...

    Interface ShaderSources

    Picking the shader language a batch compiles in, and putting the source where the engine will look for it.

    WebGPU speaks WGSL. Handing it GLSL is not an error — Babylon transpiles — but the transpilers are two WASM modules it downloads from cdn.babylonjs.com the first time a GLSL shader is compiled. That is a third-party request on first draw, a hard failure under a Content-Security-Policy that does not list the CDN or with no network at all, and a GLSL to SPIR-V to WGSL round trip before the first particle appears. Shipping the WGSL means none of that happens.

    The two languages live in separate stores keyed by the same name, so a scene that somehow ran both would not collide.

    interface ShaderSources {
        glsl: string;
        wgsl: string;
    }
    Index
    glsl: string

    GLSL source, used on every WebGL engine.

    wgsl: string

    WGSL source, used on WebGPU.