Live data from Hacker News

Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

github.com

1–10 of 226 posts

Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

#1
Creator here. I built ChartGPU because I kept hitting the same wall: charting libraries that claim to be "fast" but choke past 100K data points.

The core insight: Canvas2D is fundamentally CPU-bound. Even WebGL chart libraries still do most computation on the CPU. So I moved everything to the GPU via WebGPU:

- LTTB downsampling runs as a compute shader - Hit-testing for tooltips/hover is GPU-accelerated - Rendering uses instanced draws (one draw call per series)

The result: 1M points at 60fps with smooth zoom/pan.

Live demo: https://chartgpu.github.io/ChartGPU/examples/million-points/

Currently supports line, area, bar, scatter, pie, and candlestick charts. MIT licensed, available on npm: `npm install chartgpu`

Happy to answer questions about WebGPU internals or architecture decisions.

Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)
github.com

Re: Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

#3
Wa, this is smooth, man. This is so cool. This is really sexy and cool, the examples page (https://chartgpu.github.io/ChartGPU/examples/index.html) has many good.

I hope you have a way to monetize/productize this, because this has three.js potential. I love this. Keep goin! And make it safe (a way to fund, don't overextend via OSS). Good luck, bud.

Also, you are a master of naming. ChartGPU is a great name, lol!

Re: Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

#5

Wa, this is smooth, man. This is so cool. This is really sexy and cool, the examples page ( https://chartgpu.github.io/ChartGPU/examples/index.html ) has many good. I hope you have a way to monetize/productize this, because this has three.js potential. I love this. Keep goin! And make it safe (a way to fund, don't overextend via OSS). Good luck, bud. Also, you are a master of naming. ChartGPU is a great name, lol!

Thanks! The name was honestly just "what does this do" + "how does it do it" haha.

Interesting you mention three.js - there's definitely overlap in the WebGPU graphics space. My focus is specifically on 2D data visualization (time series, financial charts, dashboards), but I could see the rendering patterns being useful elsewhere.

On sustainability - still figuring that out. For now it's a passion project, but I've thought about a "pro" tier for enterprise features (real-time collaboration, premium chart types) while keeping the core MIT forever. Open to ideas if you have thoughts.

Appreciate the kind words! :)

Re: Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

#6
post #4

This looks great. Quick feedback, scrollbars don't work well on my mac mini M1. The bar seems to move twice as fast as the mouse.

Thanks for the bug report! That's the data zoom slider - sounds like a momentum/inertia scrolling issue on macOS.

Which demo were you on? (million-points, live-streaming, or sampling?) I'll test on M1 today and get a fix out.

Really appreciate you taking the time to try it :)

Re: Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

#7
No Firefox support? It has had WebGPU support since version 141.

Even when I turn on dom.webgpu.enabled, I still get "WebGPU is disabled by blocklist" even though your domain is not in the blocklist, and even if I turn on gfx.webgpu.ignore-blocklist.

Re: Show HN: ChartGPU – WebGPU-powered charting library (1M points at 60fps)

#9
Fun benchmark :) I'm getting 165 fps (screen refresh rate), 4.5-5.0 in GPU time and 1.0 - 1.2 in CPU time on a 9970x + RTX Pro 6000. Definitely the smoothest graph viewer I've used in a browser with that amount of data, nicely done!

Would be great if you had a button there one can press, and it does a 10-15 second benchmark then print a min/max report, maybe could even include loading/unloading the data in there too, so we get some ranges that are easier to share, and can compare easier between machines :)

Post reply on HN