Processing should define Array just like it has Vector

When Processing was first created it was a basic programming IDE that enabled non-programmers, graphics artists etc. an easy to introduction to creating computation art / graphics. It did not create a new language rather it provided a wrapper for Java that hid many of its complexities, in particular OO (object orientated) syntax and semantics.

So effectively it had a single mode “Java” and became thought of as a new language, the “Processing language”. Today Processing is an IDE that supports multiple modes / languages.

Available modes:

Although there is similarity between Java mode and p5js it is unrealistic for them to have an identical API since the underlying languages have different syntax and semantics…

Actually the Java mode vector is called PVector and Javascript does have a vector class p5.Vector. Personally I would refute the need for an identical API because both implementations would sink to the lowest common denominator.

Having said all that the question arises as to whether Java mode and p5js should provide an implementation of a 2D or even nD array. I think it would make a nice addition but the API would need careful planning because once released it would be problematic to change its implementation / API.

1 Like