<canvas /> based triangle wallpaper generator

(Dave Adlakha-Russell) #1

I really like images made up of tessellating geometric shapes, so I made a thing which generates wallpaper-sized images made up of triangles.

It renders everything on a <canvas>, grabbing colours from the ColourLovers API. There are a few customisation options, but the defaults should result in pleasant enough images.

It’s available here to have a play with. The source is also available.

The code needs some heavy refactoring, but the project is otherwise feature complete.

(Marc Cooper) #2

Very nice.

I tried your demo but got:

(Dave Adlakha-Russell) #3


I think that error might be due to accessing via HTTPS. The ColourLovers api is accessed via HTTP and so is likely getting blocked by the browser.

(Daniel Hollands) #4

Hey, this looks good. I wonder if it’s worth trying to make it work with https://randomcolor.llllll.li/

(Marc Cooper) #5

Ah, okay. You might want to fix that, though.

Like you, I enjoy tessellations. It would be awesome if you could extend your work to include Penrose tiles.

(Dave Adlakha-Russell) #6

Thanks! I’ve not come across that before and it looks quite handy.

I totally agree it’d be nice to have, though ColourLovers doesn’t accept HTTPS requests to their API. Writing a proxy is a bit overkill for this project, though it might be a good use case for the random colour lib @LimeBlast suggested.

Thanks for suggesting the Penrose tiles - that’s definitely going on my to-do list!

(Andy Wootton) #7

Taking an arguably different path but I think you’ll see why, @standupmaths does spreadsheet selfies: