Skip to main content
100%

Svelte + D3 + Regl starter (WebGL)

✓ Published3🌍 Public
MMatthias Stahl
Last edited Nov 26, 2025
Created on Feb 12, 2024

This example displays 100,000 colored dots of varying sizes and opacities on a WebGL canvas, with an overlay text reporting the total count. The visualization uses Svelte to manage the application state and interface, D3 for generating the data—including coordinates, radii via `randomExponential`, a warm color scale via `scaleSequential` and `interpolateWarm`, and opacities—and the regl library to render the points as a canvas-based WebGL scene. A custom regl fragment defines the dot shape with antialiasing, while blending controls the visual stacking of overlapping points.

AI-generated description
MIT Licensed

Similar vizzes