[Java 3D] with JOGL810574 Nov 19, 2010 9:54 AM
Hi,.
This content has been marked as final. Show 5 replies
1. Re: [Java 3D] with JOGLInteractiveMesh Nov 21, 2010 1:55 PM (in response to 810574)Hi,
Java 3D is a high level 3D API in contrast to the low level 3D APIs OpenGL, Direct3D, and the corresponding wrapper APIs like JOGL and LWJGL.
The Java 3D engine can be run on any of these rendering pipelines: OpenGL, OpenGL/JOGL, or Direct3D. The default pipeline on Windows and Linux is OpenGL, on Mac OS X OpenGL/JOGL. If OpenGL is not available on Windows the engine switches to Direct3D. JOGL is used in Java 3D to avoid an implemention of the JNI/OpenGL-interface for Mac OS X as it is done for Windows and Linux. To choose OpenGL/JOGL on Windows/Linux the system variable 'j3d.rend' has to be set to 'jogl' and to choose Direct3D on Windows the system variable has to be set to 'd3d'. The default value is 'ogl'.
From the Java 3D application point of view the rendering pipeline is not relevant. The public Java 3D API is independant of the rendering pipeline. Only a few Appearance attributes are not supported on Direct3D.
So, all Java 3D tutorials, sample programs, or your applications can be run on all pipelines and can't be/don't have to be adapted to OpenGL, OpenGL/JOGL, or Direct3D. You don't have direct access to the pipelines from within your Java 3D application.
I'm not aware of any advantages for running Java 3D on the OpenGL/JOGL pipeline. On the Direct3D pipeline a faster Java 3D rendering can be achieved than on OpenGL.
JOGL 1.1.1a is the preferred release to run Java 3D. AFAIK JogAmp's JOGL 2 fork is not downwards compatible. I assume the current Java 3D release wouldn't benefit from it. I'm not aware of anyone working on a next Java 3D release which includes a future JOGL release. I started a Java 3D fork (JUniversal3D, not public yet) and I dropped JOGL as an intermediate API for accessing OpenGL.
Oracle.Sun stopped all its 3D engagements (Java 3D, JOGL, Wonderland) and hasn't made any substantial anouncement about 3D rendering capabilities for its future JavaFX 2.0. So, it's up to third parties to supply 3D APIs for Java desktop and web applications.
August
2. Re: [Java 3D] with JOGL810574 Nov 22, 2010 3:31 PM (in response to InteractiveMesh)Thank you, August, for this.
I got a better view of the situation now.
Actually, the benefit would be the GL ES support, but maybe J3D already support it.
That's the thing I didn't uderstand : "the system variable 'j3d.rend' has to be set to 'jogl'".
I could try this now.
Bye :)
Edited by: Djak on 22 nov. 2010 07:30
Edited by: Djak on 22 nov. 2010 07:31
3. Re: [Java 3D] with JOGLInteractiveMesh Nov 24, 2010 10:06 AM (in response to 810574)Sorry, the right wording is 'system property'. Java 3D system properties can be set as follows:
I. In your myJava3DApplication.bat/sh-file "java -Dj3d.rend=jogl -cp ... "'
or
II. See javadoc of 'java.lang.System': System.setProperty(String key, String value).
On the Wiki page 'Java3DApplicationDevelopment' you will find more about Java 3D system properties
public class MyJava3DApplication { public static void main(String[] args) { // To be called before any Java 3D class is imported System.setProperty("j3d.rend", "jogl"); new MyJava3DApplication(); } public MyJava3DApplication() { } }
August
4. Re: [Java 3D] with JOGL810574 Nov 25, 2010 10:47 AM (in response to InteractiveMesh)Thanks you :)
I tested and it works fine with JOGL 1.1.1.
But, I need to use GL ES from JOGL2.0.
Cya
Edited by: Djak on 25 nov. 2010 02:47
5. Re: [Java 3D] with JOGL743856 Feb 7, 2011 10:32 AM (in response to 810574)Hi, if your question is still actual i can advice you one book writen by Andrew Davison.It' describe best practice of working with JOGL, i read it now and i like it so much, i think it'll be very usefull for you.
Take it easy.
Edited by: Ishikawa on 06.02.2011 23:52
Edited by: Ishikawa on 07.02.2011 2:32