Spark 2.0 - World Labs' open-source web-based 3D Gaussian sputtering rendering engine
Spark 2.0 is an open-source web-based 3D Gaussian sputtering rendering engine developed by World Labs (founded by Fei-Fei Li), built on Three.js and WebGL2. Spark 2.0 pioneered the LoD (Level of Detail) system, progressive streaming, and virtual memory...
What is Spark 2.0?
Spark 2.0 is an open-source web-based 3D Gaussian sputtering rendering engine developed by World Labs (founded by Fei-Fei Li), built on Three.js and WebGL2. Spark 2.0 pioneered the LoD (Level of Detail) system, progressive streaming, and virtual memory technology, enabling real-time rendering of massive 3D worlds with over 100 million splats in browsers on any device, including desktops, mobile phones, and VR devices. It achieves smooth, progressive loading of scenes from coarse to fine, breaking through the scale and performance bottlenecks of traditional Web 3D rendering, and making real-time interaction and immersive, smooth browsing of massive scenes possible.
Key features of Spark 2.0
- Ultra-large-scale scene renderingIt supports streaming and real-time rendering of a massive 3D world containing over 100 million splats in browsers on any device, including desktops, mobile phones, and VR devices.
- Global Composition of Multiple ObjectsSimultaneously render multiple independent 3DGS objects and automatically perform a unified global depth sort on all splats to ensure that different objects are correctly blended in space rather than simply superimposed.
- Continuous LoD Level of DetailBy constructing a LoD Splat Tree hierarchical structure, the optimal tree cutting line is dynamically calculated based on camera distance and viewing angle, automatically displaying high precision at close range and low precision at distant range, achieving a smooth and seamless transition of details.
- Progressive streamingIt adopts a self-developed .RAD file format, which immediately presents a rough version of 64K splats when the scene is first loaded. It downloads and refines the data of the visible area according to the viewpoint, so as to achieve a smooth experience of fine-tuning while transmitting.
- Virtual memory management: Allocate a fixed GPU memory pool as page tables for splats, and automatically retrieve and replace data blocks from the network based on the user's real-time location in the scene, thus overcoming the memory limitations of mobile devices to access massive amounts of data.
- Foveation-based rendering optimizationFoveated Rendering technology automatically shifts the rendering budget toward the center of the field of view, reducing the level of detail at the edges of the screen and in areas behind the camera, thus significantly improving the frame rate without affecting subjective image quality.
- Real-time editing and relightingIt supports real-time editing, color adjustment, and dynamic relighting of 3D Gaussian sputtering scenes directly in the browser, allowing users to see the effects of modifications without offline preprocessing.
- Programmable special effects systemIt provides a GLSL-based code interface and a visual shader graph node system, supporting developers to create rich custom visual effects such as dynamic animations, SDF geometric clipping, and transparency adjustments.
Technical principles of Spark 2.0
- 3D Gaussian sputtering baseSpark 2.0 uses 3D Gaussian Splatting technology, which replaces the traditional triangular mesh with millions of semi-transparent 3D ellipsoids (splats) to represent the scene. Each splat is defined by position, scale, rotation, color and opacity, and the final image is formed by the GPU through depth-order blending and rendering.
- Three-step rendering pipelineThe system adopts an architecture of "generating a global list → global depth sorting → instantiating and drawing". It transforms multiple object splats into a unified coordinate system and applies dynamic effects (animation, clipping, etc.). The rendering order is determined by the CPU cardinality sort after the distance is calculated by the GPU. Finally, a single drawing call completes the rasterization of all splats.
- Continuous LoD Splat TreeTo address the rendering pressure of hundreds of millions of splats, Spark builds a hierarchical tree structure from the bottom up, merging child nodes into parent nodes to form a multi-resolution representation. At runtime, it dynamically calculates the optimal "tree cut line" within a fixed budget (500,000-2.5 million splats) using a priority queue, achieving a smooth transition from near-fine to far-coarse.
- Progressive streamingThe system uses a self-developed .RAD format to divide the data into blocks (64K splats each) and compress them in a columnar manner. The file header records a random access index, allowing the scene to be presented in a rough 64K version in real time. The refined data blocks are then dynamically downloaded via HTTP range requests based on the viewpoint, enabling progressive loading that allows users to view the scene as they download it.
- Virtual memory management: Allocate a fixed GPU memory pool as the splat page table, dynamically determine the data blocks required by the current viewport based on the LoD tree traversal results, and automatically fetch new data from the network and replace old data when the user moves, enabling the browser to access a massive number of splats far exceeding the local memory limit.
- LoD Tree Generation AlgorithmIt provides two training-free algorithms for constructing hierarchical structures: Tiny-LoD (based on fast merging of spatial grids, using sorting instead of hashing to optimize caching, suitable for real-time webpage generation) and Bhatt-LoD (based on Bhattacharyya distance metric Gaussian similarity for high-quality merging, suitable for offline processing).
How to use Spark 2.0
-
Environmental introductionInstall Spark 2.0 and Three.js in your project via CDN or npm, and ensure that the target browser supports the WebGL2 standard.
-
Basic loadingFor small-scale scenarios, direct call
loadSplatThe method loads the raw 3DGS file in PLY, SPZ, or Splat format and adds it to the Three.js scene. -
Large-scene preprocessingFor large-scale scenarios with over 100 million splats, use command-line tools.
spark build-lodConvert the original file offline to the .RAD format that supports progressive streaming. -
StreamingCall in code
loadRadThe method loads the converted file and configures the splat rendering budget and foveated rendering parameters to control the level of detail and performance. -
Rendering update: Continuously call the splat object within the animation loop
updateThe method takes the current camera parameters as input and automatically performs depth sorting and LoD detail switching. -
Multi-object compositionWhen loading multiple LoD objects simultaneously, Spark automatically traverses the splat tree of all objects and uniformly allocates the global rendering budget to achieve seamless integration.
Key information and usage requirements for Spark 2.0
- Product PositioningWorld Labs (founded by Fei-Fei Li) is an open-source web-based 3D Gaussian sputtering (3DGS) rendering engine built on Three.js and WebGL2. It can render large-scale 3D scenes of over 100 million splats in real time in any device browser.
- Core technologies① LoD Splat Tree (continuous level of detail, dynamically selecting rendering precision); ② Progressive streaming (.RAD format, first presenting a rough version and then refining as needed); ③ Virtual memory (dynamically replacing data blocks within a fixed GPU memory pool).
- PerformanceSupports all platforms including desktop, iOS, Android, and VR, breaking through device memory limitations and enabling a smooth experience of downloading and interacting simultaneously.
- Environmental requirements:
-
support WebGL2 Modern browsers (Chrome, Safari, Firefox, Edge, etc.).
-
No WebGPU required, wider compatibility
-
- Hardware supportDesktop, mobile (iOS/Android), VR devices (Quest 3, Apple Vision Pro, etc.).
The core advantages of Spark 2.0
-
Ultra-large scale carrying capacityBreaking through the limitation that consumer-grade devices typically only support 1-5 million splats, it can render massive scenes of 100 million+ splats in real time.
-
Instant streaming experienceUsing a self-developed .RAD format and progressive transmission technology, scenes are presented in real time using a rough 64K version, without waiting for hundreds of MB of data to be fully downloaded.
-
Seamless compatibility across all platformsBuilt on WebGL2, it covers desktop, iOS, Android and VR devices, so there's no need to worry about API support differences.
-
Intelligent detail balanceThe unique continuous LoD Splat Tree system dynamically adjusts the accuracy based on the viewing distance and gaze point, resulting in near images appearing sharp and distant images appearing blurry with a smooth transition and no jumps.
-
Multi-object global fusionIt supports loading multiple independent 3DGS objects simultaneously and automatically performs global depth sorting across objects, solving the "texture overlay" problem of traditional renderers.
-
Seamless memory expansionBy using a virtual memory page table mechanism, data blocks are automatically swapped from the network, enabling browsers to access massive amounts of resources far exceeding the local GPU memory limits.
Spark 2.0 project address
- Project official website: https://www.worldlabs.ai/blog/spark-2.0
- GitHub repositoryhttps://github.com/sparkjsdev/spark/
Spark 2.0 Competitive Product Comparison
| Comparison Dimensions | Spark 2.0 | Luma AI |
|---|---|---|
| Product Form | An open-source JavaScript library that developers can deeply customize, deploy privately, and integrate with as needed. | A closed-source SaaS platform that provides standardized upload-view hosting services. |
| Real-time editing | Supports real-time modification of splat attributes, color adjustment, SDF cropping, and dynamic effects within the browser. | Only fixed-view browsing and preset paths are provided; real-time parameter adjustment is not supported. |
| Data sovereignty | Supports multiple input formats such as PLY/SPZ/Splat and is open to the .RAD standard, allowing for complete data autonomy. | Closed ecosystem, only supports specific formats generated by the platform, export is restricted. |
| Scene Scale | With LoD system intelligent memory management, you can smoothly browse ultra-large-scale city-level scenes. | Due to limitations in platform processing capacity and subscription levels, extremely large-scale scenarios may require queuing or processing at reduced quality. |
| Cost structure | Free and open source; you only need to bear the costs of your own server bandwidth and storage. | Subscription-based pricing based on usage, export resolution, and API calls. |
| Offline capabilities | Supports fully offline environments or private CDN deployments, requiring no external network dependency. | Requires continuous internet access to Luma cloud services and depends on platform availability. |
Application scenarios of Spark 2.0
-
Digital Twins and Urban GovernanceIt is used to build a city-level digital twin foundation, supporting real-time browsing of a smart city 3D model containing tens of millions of splats in a browser, enabling remote inspection and management without the need to deploy heavy client software.
-
VR/AR immersive experience: For large-scale immersive roaming on VR/AR headsets, allowing you to smoothly explore massive virtual cultural tourism and world-building scenarios in Quest 3 or Apple Vision Pro.
-
Real-time content creationIt is used for real-time collaboration and content creation based on web pages, and supports real-time editing, relighting and dynamic effects adjustment of AI-generated 3D worlds directly in the browser.
-
Online exhibitions and e-commerceUsed for online displays of museums, art exhibitions, and real estate, it allows users to instantly browse large-scale digital scenes without waiting for a full download through progressive streaming technology.
-
Web games and virtual eventsUsed for open-world web games and virtual concerts, enabling streaming scene loading that allows players to download while playing, and supporting real-time interactive rendering of ultra-large-scale virtual environments.