Based on what I want to do - should I learn Processing or P5.js?

I have a month off to dive full time into learning a visual framework and am unsure which direction to dedicate my time to.

I am a musician and build generative and sonification systems. I have never touched any visual frameworks but want to start using something along with my sound work. My goal is simple - I want to generate abstract, evolving art that is in responsive to the audio input. I might also want to put the program on a pi with a small lcd.

I am comfortable with JavaScript, C, Obj C, Csound, Max/MSP, Smalltalk.

Given my goals, is there a benefit to learning Processing over P5.js? Or should I just go with the latter?

Thanks in advance.

1 Like

Look at :

Then if you are confortable with JavaScript, go for p5.

But I think that Processing is more appropriate to use sound libraries like Minim and interacting with Pi.

1 Like

Hmmm. Now I’m more unsure which direction to focus on…

1 Like

p5.js is easier to learn and more adaptable, processing is java so its waay faster and can be exported to an EXE (but not really a secure one you need external sources for that) . There are ways to make a JavaScript exe using https://electronjs.org/ and such but Its truly meant for web development and p5.ja just makes the visual waay easier, allowing you to do things without really having to edit css or html (but it is good to know how to) or any stuff like that. p5.js and processing have in-depth tutorials by Daniel Shiffman https://www.youtube.com/channel/UCvjgXvBlbQiydffZU7m1_aw

I agree with @josephh that it sounds like you would benefit more from using/learning Processing instead, because I feel you’re leaning more on the live performance side of things, and processing.java would be more appropriate for that.

3 Likes

If you pick Processing, prob. you’re gonna use Minim:
http://Code.Compartmental.net/minim/

If you pick p5js, prob. you’re gonna use p5.Sound:
https://p5js.org/reference/#/libraries/p5.sound

1 Like

The sound examples are simple.

You can run from both languages and make a comparison yourself.

For online distribution p5.js is your best bet

1 Like

Thanks for the replies. I spent the day with p5.js and had a blast creating a sketch with fft and greyscale lines :wink: It’s been super easy for me to learn so far.

So based on what you have said, it seems like Processing might be more robust for my needs? It also looks like minim is has more capabilities than sound.js?

1 Like

It depends what you are using the music for. If it is going onto the web, then it would be useful to know p5.js but honestly in the long term I recommend learning both.

Actually, most of the music would be created externally, with synthesizers and other music specific software I use. I am not getting into Processing for sound synthesis but only for visuals. So I would most likely want to feed the fft analysis audio and have it generate visuals based on the input.

1 Like

That sounds cool and again it really matters WHERE you want to put those awesome visuals. If you are going to do it on a website it needs to be in p5.js. for an app/exe then you should use processing

Maybe it would make sense to just always run my apps in a browser? So even if I have an installation or performance, the visual would be loaded on a full screen browser. That way I can focus only on p5.js and have something I can use for performance or web. Does that sound like it has any drawbacks?

1 Like

The only drawback there I see is that you would not be able to make an application, it would be on the web and run a bit slower, but probably not slow enough to matter It is easier to do what you want to do on p5.js also, and if you ever want some help just ask :slight_smile:

1 Like