Kevin Mamaqi
Kevin Mamaqi

Reputation: 355

Generative art javascript library without node-canvas?

I am looking for a javascript library that can be run in different servers, but not node.js (for a WordPress site), capable of doing this: https://color-wander.surge.sh/ or something similar.

Upvotes: 1

Views: 1124

Answers (2)

George Profenza
George Profenza

Reputation: 51837

How about something starting with a client side option you can upload to any web server afterwards ?

The are quite a few creative coding javascript libraries out there. The simplest to get started with I can think of is p5.js

Have a look at the p5.js Brownian Motion example brownian motion p5.js sample

On Wordpress, have a look at this article:Embedding p5.js in a WordPress entry

Additionally there's an p5.js video course

Upvotes: 1

Joat Mofa
Joat Mofa

Reputation: 81

If you use the developer tools you can see that it uses a java-script called bundle.js - you can run that through some unminify program to make it readable but I think there is nothing node specific about it.

You can just download index.html and bundle.js You will also need some maps in a subdirectory called maps - sym6.jpg, sym3.jpg, scifi.jpg, nature1.jpg, map7.jpg, geo5.jpg, geo4.jpg and so on

Then you can just run the page and script locally without any need of node.js I just did that and ran it with SimpleHTTPServer of python and it works just fine - you need a server because the maps get loaded

The site itself - color-wanderer.surge is using node and if you want to list the maps directory it will tell you that but the source tab in the developer tools shows you that for different seeds it just wants different maps.

So really there should be no problem getting it into WordPress.

Upvotes: 1

Related Questions