Processing 4.x releases (currently in “beta”) that use Java 11
Processing 4 makes important updates to the code to prepare the platform for its future. Most significantly, this includes the move to JDK 11 and support for new Java language features. The changes should be transparent to most users, but because of the massive shift behind the scenes, this is 4.0.
We've also moved to a new repository for this release so that we could cull a lot of the accumulated mess of the last 20 years, which makes
git clone(and most other
gitoperations) a lot faster.
This software is currently in beta. We don't have a schedule for the final 4.0 release. This work is being done by a tiny number of people who continue working on it, unpaid, because they care about it. The beta is the default download on the site because it's more usable than the 3.5.4 release.
We're currently using JDK 11, which is a “Long Term Support” (LTS) release. Java 17 is now available and is the next LTS, and we'll switch to that when we have time. You can track that progress or give us a hand with that here.
The current release runs well on Apple Silicon using Rosetta. We are currently unable to move to a fully native version for Apple Silicon because of other libraries that we rely upon (JavaFX, JOGL, etc). Once those are ready, we'll need to do additional work to add Apple Silicon as a target (the same way we support both 64-bit and 32-bit, or ARM instead of Intel.) If you'd like to help, or would like to check for updates, you'll find more here.
As with all releases, we'll do everything possible to avoid breaking API. However, there will still be tweaks that have to be made. We'll try to keep them minor. Our goal is stability, and keeping everyone's code running.
The full list of changes can be seen in the release notes for each version, this is only a list of things that may break existing projects (whether sketches, Libraries, Modes, etc.)
colorcan be part of package names, which gets some older code (i.e. toxiclibs) running again.
protected, now it's
Editor.showConsole(). Does not appear to be in use anywhere, easy to add back if we hear otherwise.
getCompositionTextPainter(). This was an internal function and inconsistent with the rest of the function naming.
~~Known bug: code completion is currently broken. Any updates will be posted here.~~ Fixed in alpha 6.
Moved from the 11.0.2 LTS version of JavaFX to the in-progress version 16. This fixes a garbled text issue that was breaking Tools that used JavaFX.
The minimum system version for macOS (for the PDE and exported applications) is now set to 10.14.6 (the last update of Mojave). 10.13 (High Sierra) is no longer supported by Apple as of September or December 2020 (depending on what you read), and for our sanity, we're dropping it as well.
JavaFX has been moved out of core and into a separate library. After Java 8, it's no longer part of the JDK, so it requires additional files that were formerly included by default. The Processing version of that library comes in at 180 MB, which seems excessive to include with every project, regardless of whether it's used. (And that's not including the full Webkit implementation, which adds ~80 MB per platform.)
EditorState(List editors)changed to
EditorState.nextEditor(List editors), reflecting its nature as closer to a factory method (that makes use of the Editor list) than a constructor that will also be storing information about the list of Editor objects in the created object.
export.include_javawhich also embeds a string for the platform for better localization support.
~~The minimum system version for macOS (for the PDE and exported applications) is now set to 10.13.6 (the last update of High Sierra). Apple will likely be dropping support for High Sierra in late 2020, so we may make the minimum 10.14.x by the time 4.x ships.~~
changes.mdif you're using
surface.setResizable()with this release on macOS and with P2D or P3D renderers.~~
PApplethave been removed. These were not documented, hopefully they were not in use anyway.
frameobject has been removed from
PApplet. We've been warning folks to use
surfacesince 2015, but maybe we can provide an easy way to update code from inside the PDE.
All AWT calls have been moved out of
PImage, which may be a problem for anything that was relying on those internals
new PImage(java.awt.Image)is no longer available. It was an undocumented method that was
publiconly because it was required by subclasses.~~ As of alpha 4, this is back, because it wasn't deprecated in 3.x, and is likely to break too many things.
MouseEvent.getAmount(). These had been deprecated, not clear they were used anywhere.
Processing 4 is 64-bit only. This is the overwhelming majority of users, and we don't have the necessary help to maintain and support 32-bit systems.
Instructions on how to build the code are found in a README inside the