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

    Interface SceneGraphNode

    Scene graph node for UI display. Simplified version of SceneNode from data-loader-types.ts.

    interface SceneGraphNode {
        path: string;
        name: string;
        type: NodeTypeName;
        pointCount?: number;
        visiblePointCount?: number;
        segmentCount?: number;
        visibleSegmentCount?: number;
        vertexCount?: number;
        splatCount?: number;
        faceCount?: number;
        visibleSplatCount?: number;
        visibleFaceCount?: number;
        kind?: NodeKind;
        displayType?: "points" | "lines" | "gsplats" | "mesh";
        lodGroupChildCount?: number;
        partCount?: number;
        additiveSublods?: number;
        hasSpatialIndex?: boolean;
        children: SceneGraphNode[];
        isExpanded?: boolean;
    }
    Index
    path: string

    Path in the zarr store

    name: string

    Display name (last component of path or 'Scene')

    Node type

    pointCount?: number

    Number of points (for points nodes)

    visiblePointCount?: number

    Number of visible points after nD slicing (for points nodes)

    segmentCount?: number

    Number of segments (for lines nodes)

    visibleSegmentCount?: number

    Number of visible segments after nD slicing (for lines nodes)

    vertexCount?: number

    Number of vertices (for lines nodes)

    splatCount?: number

    Number of splats (for gsplats nodes)

    faceCount?: number

    Number of triangles (for mesh nodes).

    Faces rather than vertices, because this trio counts the DRAWN PRIMITIVE per type — note lines is counted by segmentCount, not vertexCount, for the same reason. (The Python Mesh.n_elements counts vertices instead, since there the primary element is whatever the per-element attribute arrays are indexed by. The two conventions answer different questions.)

    Populated from the node's n_faces attr by scene-graph-converter.ts now that the mesh loader has landed. Still optional: elementCountOf treats a missing count as 0, so a store that omits the attr degrades to zero rather than NaN.

    visibleSplatCount?: number

    Number of visible splats after nD slicing (for gsplats nodes)

    visibleFaceCount?: number

    Number of visible triangles after nD slicing (for mesh nodes) — the fourth member of the visible-count family above.

    A mesh loads WHOLE, so this is not a streaming residency figure like its siblings: it is how many of the node's faces the active nD slab indexes, which is what commit-mesh-geometry puts in the index buffer. Pushed per path by monitor/visible-counts.ts and merged in by SceneGraphModel.syncVisibleCountsIntoTree.

    kind?: NodeKind

    Specialized-group discriminant, set when the underlying scene-graph node is a kind=lod (substitutive LOD) or kind=partition (BSP) Group. Drives the tree's kind badge + icon. Mirrors LayerInfo.kind in ui/layers/layer-state.ts. NodeKind is single-sourced from the cross-language format contract (format-contract/contract.yaml).

    displayType?: "points" | "lines" | "gsplats" | "mesh"

    Resolved geometry display_type for a specialized group — the type the user logically sees the group as. Absent for plain groups and leaves (use type there).

    Spelled out rather than GeometryTypeName: this is the LOD/partition-CAPABLE subset of the vocabulary — the UNION of LODGroupMetadata.display_type and PartitionGroupMetadata.display_type, since one field carries both kinds. So do not widen it when a geometry type is added — declare that type's lod / partition capabilities in types/geometry-capabilities, and extend this union only if one of them comes out true. 'mesh' is here on both counts: its lod and partition flags are now both true.

    lodGroupChildCount?: number

    For kind=lod groups: number of substitutive levels (child count).

    partCount?: number

    For kind=partition groups: number of BSP parts (child count).

    additiveSublods?: number

    For additive-LOD leaves (n_additive_sublods > 1): the total number of additive sublods. A structural marker (the additive_<i> subgroups are hidden from the scene graph) so the tree can always render a "LOD x/N" progress slot; the live loaded/refining values come from LODProgressProvider.

    hasSpatialIndex?: boolean

    Whether this node has a spatial index

    children: SceneGraphNode[]

    Child nodes

    isExpanded?: boolean

    UI state: whether node is expanded in tree view