1

We have a Java application running on Linux. The application needs to display images (with jogl). My computer has two video cards, one is the integrated video card and another is a NVIDIA added by our engineer.

I am just wondering is it possible for the Java application to choose which video card to use? how about dynamically?

peterboston
  • 877
  • 1
  • 12
  • 24
  • "*[...] is it possible for the Java application to choose which video card to use?*" - In general, no. Java cannot communicate with specialized hardware like graphic cards or webcams. There is, however, the possibility to use the JNI to communicate with the hardware's driver directly. – Turing85 Dec 26 '19 at 15:29
  • Does this answer your question? [Using Java with Nvidia GPU's (cuda)](https://stackoverflow.com/questions/22866901/using-java-with-nvidia-gpus-cuda) – MWiesner Dec 26 '19 at 15:56

1 Answers1

1

This question has already been answered on the official JogAmp forum. At first, there is no cross-platform GPU manufacturer agnostic way of doing that in plain OpenGL. NVidia GPU affinity extension is not exposed in JOGL and anyway, it would not work with non NVidia hardware.

gouessej
  • 3,640
  • 3
  • 33
  • 67