Raspberry Pi 8 giga

The new Raspberry Pi 4 with 8giga is out!!
Is there any chance to update processing for pi to follow the raspberry pi progress? Right now you can’t use it even with the simplest sketch around.
We have gave the new raspberry pi is with 64bit!! I think it’s the time to start working on it again!

1 Like

Should be emminently possible. I,ve developed my PiCrate gem (processing in ruby) to work with Manjaro Arm (64 bit). Also runs fine with RaspberryPi OS (formerly Raspbian Buster) on my RaspberryPi4. I doubt processing.org have the resources to support it though. See Experiments with RaspberryPi and 64 bit.

1 Like

Your project it’s great. But you need to know ruby.
I would love to just use processing and use it on pi. I don’t even know the work behind to upgrade processing for a raspberry pi 4. Can you give me an idea?

What my code is missing is the processing ide and the Antlr parser. Although it should be more or less compatible with pure java code (eg code developed for processing using a standard java ide). It’s the Antlr parser that allows you to create a sketch without apparently creating an instance of a java class. When using the processing ide it emits the java code (into a temp file somewhere in the /tmp folder on linux) and that gets compiled to a class in another folder. Which is what gets used when the sketch gets run.
So a simple sketch in ide:-

void setup() {
  size(200, 200);
}

void draw(){
  background(color(200, 0, 0));
}

becomes:-

/* autogenerated by Processing preprocessor v3.0.0 on 2020-06-01 */
import processing.core.*;
import processing.data.*;
import processing.event.*;
import processing.opengl.*;

import java.util.HashMap;
import java.util.ArrayList;
import java.io.File;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;

public class sketch_200601a extends PApplet {

 public void setup() {
  /* size commented out by preprocessor */;
}

 public void draw(){
  background(color(200, 0, 0));
}

  public void settings() { 
     size(200,200);
 }

  static public void main(String[] passedArgs) {
    String[] appletArgs = new String[] { "sketch_200601a" };
    if (passedArgs != null) {
      PApplet.main(concat(appletArgs, passedArgs));
    } else {
      PApplet.main(appletArgs);
    }
  }
}

If you can live with nuisance of adding the java boilerplate, you don’t need the ide or parser, fortunately with JRuby I am able to avoid using a pre-processor yet provide quite clean code.

2 Likes

If you are not to put off by needing to write pure java code (and setting up CLASSPATH to processing jars), the specific changes I made for Buster (32 bit):-
Were to get rid off Gottfreid Haiders RaspberryPI fixes for PGraphicsOpenGL.java, they are no longer required (indeed get in the way). You however need to ignore the advice to use the legacy graphics driver on the RaspberryPI and use either fake KMS (or full KMS currently only RaspberryPI3B+), you also need to replace processings hacked version of JOGL-2.3.2 with the latest release candidate version of JOGL-2.4. Sam Pottingers fork of processing-4 has this change but not the changes to PGraphicsOpenGL.java. Fortunately the OpenJKD11 supplied with RaspberryPI OS is compatible, but for Manjaro I use the AdoptOpenJDK11 jdk (many stock jdk supplied by linux distros have linker issues with OpenGL). For 64bit you need appropriate versions of JOGL jars and OpenJDK.

1 Like