Luxar Viewer API Documentation - v2026.10.19
    Preparing search index...

    Module rendering/picking/gsplat/pick.tsl

    GSplat picking material TSL factory — NodeMaterial counterpart to GSPLAT_PICK_SOURCE in shaders.ts.

    Same 3D→2D covariance projection pipeline as gsplat.tsl, but the fragment outputs picking data:

    • R: nodeId (uniform)
    • G: elementId (instance index) LOW 16 bits
    • B: brightness clamped to [0, 1]
    • A: the same elementId's HIGH 16 bits (one f32 channel cannot carry the whole index exactly — see luxarElementIdParts) Depth = 1 / (1 + unclamped salience) (brightness-as-depth tie-breaking) — or the real fragment depth when uSurfaceDepth == 1 (surface/'normal' mode: front-most wins, matching the depth-sorted occluding surface).

    The amplitude and visibility weight are the VISUAL ones (the node's projection — sum-projection ray-integral boost included, selected at runtime by uProjectionMode — per-splat alpha, node opacity and gain; ../_shared/visibility-tsl.ts), so a splat is pickable exactly when it is visible.

    GSplatPickTSLNodes
    PickTextureWidthConfig
    gsplatPickWebGPUFactory
    buildGSplatPickTSLNodesFromUniforms