View Full Version : Graphics API for Java?

02 February 2004, 11:05 AM
Hello there,

does anybody know if there's something like OpenGL or DirectX for Java? Or does Java provide its own graphics API?

I'm not too proficient in Java, I'm just interested because I'm writing a simple 3D editor and I'm thinking about building my GUI in Java.

Thanks, MJ

02 February 2004, 01:00 PM
Take a look into Java3D - I haven't done much of it myself, but it's Java's built-in 3D API...

02 February 2004, 03:39 PM
My ManifoldLab (3D Editor) ...

Is built on top of OpenGL.

I'm using an old OpenGL binding that has fallen out of favor ... but who cares. The point of Java is to abstract choices like that anyway ... which could easily be done.

It might be a great place for you to start ... take all the source and fork your own app.

02 February 2004, 12:02 AM
Feature list ...

02 February 2004, 02:03 PM
thanks very much! that should really do as a reference :)

you said you used Java with an OpenGL binding. Why didn't you use Java3D? Honestly, I've never done anything with Java3D so I don't know whether its any good...

02 February 2004, 06:55 PM
OpenGL should be of much more use to a long term programmer who is looking as his skill set ... looking past the current project.

I knew that OpenGL could do all that I needed. It was a very safe bet.

Any reason why you might think Java3D over OpenGL ?

02 February 2004, 02:47 PM
Java 3d is dead! Long live Java3d!

Seriously, check out jogl ( which will most likely be a replacement for java3d. It's got opengl bindings for hardware accelerated graphics, so it can do things like shaderst. It's not very well documented, but there are Sun engineers working on it and the forums will answer most of your questions.

02 February 2004, 09:56 AM
thanks very much. that really looks promising... and you don't have to deal with yet another graphics API :)

@markyjerky: no, actually I've got no reason.
I don't know Java3D at all and I was just wondering whether anybody had some reasons to prefer Java3D over OpenGL... but as it seems there are a few OpenGL bindings for Java out there. So why bother with yet another 3D API?

02 February 2004, 02:46 PM
As a 3d programmer I would recommend using GL4Java from, or possibly writing your own API which might involve writing a few vector/matrix classes, chucking out a few primitives such as triangles etc and using native java rendeing processes when it comes to polygons etc. I'm just finishing a funky little ray tracer for non-realtime graphics - all written myself. I wouldn't dream of writing a program to comete with 3DSMAX, but it will showcase my skills nonetheless. Try to work out what you want to acheive.

02 February 2004, 03:37 PM
I'm very interested in Java3D, but apart from the alluring fact that it's a native API, it's still just software rendering. An OpenGL library is faster and more adapted towards hardware rendering.

02 February 2004, 01:20 AM
Last time I checked, the Java3D API has been pretty much left to rot. Although Apple recently released their own implementation for Mac OS X, it's a bit too late. :rolleyes:

There are interesting discussions on the (lack of) future for Java3D at Try:;action=display;num=1070879099;action=display;num=1074679694

I personally recommend learning OpenGL since it's widely used. There is far more documentation on it, and a ton of examples readily available over the Internet.

CGTalk Moderation
01 January 2006, 09:00 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.