Reputation: 81
I am using Zulu openJdk 11 for Arm. I ve tried both in IntelliJ and VsCode butting getting the same exact error.(I'm using JavaFx SDK 11.0.2) Error Message (screenshot from visual studio code)
I would really appreciate any help, I've been trying to solve this issue for days but could not find any information for especially Apple Silicon.
Thanks in advance.
Graphics Device initialization failed for : es2, sw Error initializing QuantumRenderer: no suitable pipeline found java.lang.RuntimeException: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found at javafx.graphics/com.sun.javafx.tk.quantum.QuantumRenderer.getInstance(QuantumRenderer.java:280) at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.init(QuantumToolkit.java:222) at javafx.graphics/com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:260) at javafx.graphics/com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:267) at javafx.graphics/com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:158) at javafx.graphics/com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:658) at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:409) at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:363) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:1051) Caused by: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found at javafx.graphics/com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.init(QuantumRenderer.java:94) at javafx.graphics/com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:124) at java.base/java.lang.Thread.run(Thread.java:834) Exception in thread "main" java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:1051) Caused by: java.lang.RuntimeException: No toolkit found at javafx.graphics/com.sun.javafx.tk.Toolkit.getToolkit(Toolkit.java:272) at javafx.graphics/com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:267) at javafx.graphics/com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:158) at javafx.graphics/com.sun.javafx.application.LauncherImpl.startToolkit(LauncherImpl.java:658) at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:409) at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:363) ... 5 more
Code of the project(Copied it from oracle just to test mu setup):
import javafx.application.Application;
import javafx.event.ActionEvent;
import javafx.event.EventHandler;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.layout.StackPane;
import javafx.stage.Stage;
public class JavaFX extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage primaryStage) {
primaryStage.setTitle("Hello World!");
Button btn = new Button();
btn.setText("Say 'Hello World'");
btn.setOnAction(new EventHandler<ActionEvent>() {
@Override
public void handle(ActionEvent event) {
System.out.println("Hello World!");
}
});
StackPane root = new StackPane();
root.getChildren().add(btn);
primaryStage.setScene(new Scene(root, 300, 250));
primaryStage.show();
}
}
Upvotes: 5
Views: 3315
Reputation: 61
Just for reference: I'm not using M1, just updated the system to Big Sur. But you are right about 11.0.2's outdated. For Big Sur, 11.0.2 is likely to display garbled code instead of normal letters even if the fx running properly with the warning like "CoreText note: Client requested name ".SFNS-Regular", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:]. ". To deal with that, I updated 11.0.2 to 16 and everything went well.
Upvotes: 2
Reputation: 10640
For the M1 you have to download JavaFX Mac OS X AArch64 SDK
version 17 build 14 (currently) which supports the Arm architecture. Why do you want to use an outdated version 11.0.2 anyway?
Upvotes: 3
Reputation: 61
I've updated the system and change the former fx jar then get those warnings similar to yours. (Big Sur 11.4) Here is the solution:
Upvotes: 4