[Issue] Cannot run P2D / P3D on versions 3.2.4 up to 4.0a2

I also posted this question here:

Hello there.

I am encountering a weird problem with Processing on Windows.

When running this code:

void setup() {
    size(500, 500, P2D);

I get the following error:

Error loading EGL entry points.
# A fatal error has been detected by the Java Runtime Environment:
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x0000000000000000, pid=8956, tid=0x0000000000003314
# JRE version: Java(TM) SE Runtime Environment (8.0_202-b08) (build 1.8.0_202-b08)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.202-b08 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C  0x0000000000000000
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
# An error report file with more information is saved as:
# C:\Program Files\processing-3.5.4\hs_err_pid8956.log
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
Could not run the sketch (Target VM failed to initialize).
For more information, read revisions.txt and Help ? Troubleshooting.

I have tried this on several versions, the oldest being 3.2.4, the latest being 4.0a2.
I have tried to analyze this ‘C:\Program Files\processing-3.5.4\hs_err_pid8956.log’-file, but also couldn’t find anything.

Then I installed processing-3.5.4 on my ubuntu-vm, here everything works fine! (Go Linux!)
EDIT: I now have tried to do the same stuff with my manjaro-vm (my main linux vm). Here, I get the same results as with Windows. Upon further testing with ubuntu, I realized whenever I start a P2D/P3D sketch, this warning gets printed to console:

libEGL warning: DRI2: failed to authenticate
OpenGL error 1280 at bot beginDraw(): invalid enumerant

I have read that this error might be due to a graphics driver, so I uninstalled my current driver (latest: 461.09) and uninstalled the oldest I could find on Official GeForce Drivers | NVIDIA (456.71). Sadly, same results.

Then I read here (P2D P3D not working in processing - #25 by Ruchi), that the error might appear due to Anti-Virus-Software and Windows Firewall. Therefore, I uninstalled my Anti-Virus-Software (Kaspersky), disabled Windows Defender and Windows Firewall. Same results.

I checked with the Intel Driver @ Support Assistant-Tool, that all my other drivers all also Up-to-date. My Windows is also Up-to-date.

This is my system (Laptop):
GTX1060 + Intel HD Graphics 630
Memory 16GB
Windows 10 Home 64-Bit 10.0.19042 Build 19042
Motherboard P65 - BIOS FB0E

My system has OpenGL version 4.6.0 - Build installed. This comes from OpenGL Extensions Viewer. It also claims my driver version is Intel Graphics Drivers (Nvidia GPU not listed).
EDIT: I set my preferred graphics processor in Nvidia Control Panel to the Nvidia one. OpenGL Extensions Viewer now detects my Nvidia GPU as the renderer, but no changes with my processing problem.

I myself use Java 15, but since Processing ships with its own Java 8, I hardly believe that this is the problem.
EDIT: Just to make sure, I have uninstalled Java 15 and checked Processing again. Problem still there.

The last time I really used Processing was about a year ago. Sadly, I do not remember what exact version I was using, I just remember it to be Processing 3. Back then, everything was working great. P2D and P3D code, which worked back then, now doesn’t work anymore.

Everything not using P2D or P3D is working fine. The deprecated OPENGL tag (instead of P2D, P3D, or JAVA2D), also doesn’t work.

I have absolutely no clue what is going wrong.


I have a similar problem on Linux with Intel Graphics :frowning:

Try adding this at the start of your sketch:

void settings() {
System.setProperty("jogl.disable.openglcore", "true");
size(400, 400, P2D);

Sadly that doesn’t do anything. The JVM doesn’t even start. I believe it is due to opengl, as you suspect, but your code doen’t even execute, because no JVM :cry:

1 Like