Hacker News new | ask | show | jobs
by gameguy43 2788 days ago
This sort of thing is useful for showing placeholder images while high-res images load: https://jmperezperez.com/svg-placeholders/
2 comments

I've written my own placeholder image generator based on Delaunay triangulation inspired by this blog-post. The generator produces reasonable placeholder images at about 300 bytes. The overall effect is not as nice as the images produced by Primitive though. However, Delaunay triangulation is deterministic and relatively fast. Furthermore, the triangles can be efficiently serialized as triangle strips.

In case anyone is interested, the code is on GitHub [1].

[1] https://github.com/astoeckel/aequipedis/

Unmaintained at this point, but here's a Webpack loader that does this: https://github.com/technopagan/sqip