Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Svelte + D3 + Regl starter (WebGL)

Public visualization

Svelte + D3 + Regl starter (WebGL)

2 stars3🌍 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

Comments

Sign in to join the discussion.

MIT Licensed