p5.js Bringing Processing To The Web
p5.js Bringing Processing To The Web
Written by David Conrad   
Thursday, 07 August 2014

p5.js is a JavaScript library that takes the core ideas of Processing and brings them to the web. The first public beta of this open source project has just been released.

Like Processing p5.js has the goal of making coding accessible for artists, designers, educators, and beginners. It provides users with facilities that can be summed up as "Programming for the Arts". In particular, it makes it easy to draw shapes, to add mouse interaction to your drawings and to generate sound.

These features are demonstrated in the Hello p5.js video by Daniel Shiffman, who may already be a familiar face from his Hello Processing video produced for last year's Hour of Code.



(click to run the video, you will need to use a browser that fully supports WebGL)


This isn't just a video you watch and listen to - it is one you interact with. The important point about it is that you are doing this in the browser and not on your desktop or an art installation, which is how you would be able to interact in a similar way with a program created in Processing.

p5.js isn't a port of Processing, it is a new implementation of the same objectives in JavaScript. It has the same basic structure of an initialization setup function and a draw function which is called at the frame rate. You include drawing functions which are similar to the drawing function in Processing to create the graphics and animate them. There is a short tutorial on converting from Processing to p5.js. 

As this is a JavaScript library you can interact with HTML5 objects including text, sound, webcam and video input. It will allows artist to bring their creations to the web and has an obvious role in promoting programming in the classroom.

p5.js is developed by artist and programmer Lauren McCarthy in collaboration with others including the students and faculty of the p5.js working group at the Interactive Telecommunications Program of New York University's Tisch School of Arts where Dan Shiffman is an Assistant Arts professor and Lauren McCarthy is a researcher in residence.

p5.js is in active development on GitHub and an official editing environment is billed as "coming soon" together with "many more features".


More Information


p5.js on Github

Related Articles

Processing's Hour of Code

Processing Version 2.0 Released


To be informed about new articles on I Programmer, install the I Programmer Toolbar, subscribe to the RSS feed, follow us on, Twitter, Facebook, Google+ or Linkedin,  or sign up for our weekly newsletter.



Alexa Skill Builder Beta

Arguably Alexa already has too many skills that nobody wants to make use of for more than five minutes. However, if Amazon can make it easier to create them, perhaps it increases the chance that a rea [ ... ]

Investigating Bias In AI Language Learning

A new study has revealed that AI systems, such as Google Translate, acquire the same cultural biases as humans.While this isn't a surprising finding, it comes as a cause for concern and remedial actio [ ... ]

More News




blog comments powered by Disqus

Last Updated ( Thursday, 07 August 2014 )

RSS feed of news items only
I Programmer News
Copyright © 2017 i-programmer.info. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.