Jump to content
  • Advertisement
Sign in to follow this  
SKATIN_HARD

[java] new to java3D needing advice

This topic is 5053 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I want to begin programming 3D in java. What all do I need? I went to Sun's site and I went to the download page. I have to choose between opengl or directx??? I'm not sure what one to pick or what one will be easier. Also does anybody have any links to another page where java3D is avaiable. I couldn't get it to download under going through Sun and the download manager. If anybody has a link I would appreciate it. Any info would help.

Share this post


Link to post
Share on other sites
Advertisement
Well if you doing OpenGL you might as well use JOGL. I dont know much about Java3D, but I know the Sun API isnt that great. DirectX is fairly easy I think, and I have seen plent of books for it, but people have told me the OpenGL of Java 3D is faster than DirectX.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Neither. They're both crap for games - officially (sort of)! Sun specifically does not recommend Java3d for games dev, it's recommended for Molecular Chemistry and things like that.

Instead, you want to try Xith, jME, or just use OpenGL (use LWJGL or JOGL).

Look here for details of all the different java 3d libs:

http://javagamesfactory.com/tech.html

redmilamber

Share this post


Link to post
Share on other sites
If you'd like to learn OpenGL, you have two choices
JOGL https://games-core.dev.java.net/
and LWJGL http://www.lwjgl.org/download.php
And if you'd be really crazy you'd ask me to send you an around year old version of JOGL that was modified to alow MUCH easier programming, at least less typing.

JOGL is easier for starting and debugging, LWJGL is more compact easy computer hanging library simillar to C++ version of OpenGL.

BTW a little advice when creating OpenGL window, set OpenGL so it would have distinctly colored background. This means GL.clearColor(xxxxx) different than zero or one.

Share this post


Link to post
Share on other sites
Just remember that JOGL only give you access to the hardware through OpenGL. If you want a scenegraph, then use Xith. If you need sound, input, etc. then go for LWJGL.

Share this post


Link to post
Share on other sites
Java3D can either be downloaded as the openGL or the directX version, you won't notice the difference. With some graphic cards the directX implemented version runs faster, on others, it's the openGL one, that's specific to the hardware.
I've experienced that the OpenGL version had (very) slightly more features, but these are really tiny details, nothing important (like point tranparency for example). Choose one or the other, they are both ok anyway.
And as long as you don't wanna make a Quake 46, you shouldn't have problems with performances.
And for tutorials, i advice to look at sun's tutorials, they're complete and well explained.

To come back to the above discussion, i always wonder why they compare JOGL and J3D concerning their "performances". They are different things, JOGL is a low level api whereas J3D is high level. Look out if you wanna more information, it's not the first time this kind of topic arises. And before seeking more "performances", you should ask you the question "isn't it enough?" or "where is my bottleneck?"...

I don't wanna say J3D is cool, is perfect or something like this, far from that. i just think both have their use, it's a question of what you need and what you prefer so it's idiotic to put one down or up. (but i find J3D cool :P)

Lastly,
Quote:

Sun specifically does not recommend Java3d for games dev

Where on earth did you found this? ...the link please

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Quote:
Original post by misterX
And as long as you don't wanna make a Quake 46, you shouldn't have problems with performances.


Rubbish. Java3D imposes huge overheads that are 100% entirely pointless to games development. This is one of the reasons Xith3D was started in the first place: the realization that even if Sun started supporting j3d properly, instead of throwing it in the garbage heap and leaving it to rot, it would still suck for games development.

Look at the comparisons in performance: to render the same stuff, *using the same API*, xith3d does the same scenes as much as 20%-30% faster.

Quote:

To come back to the above discussion, i always wonder why they compare JOGL and J3D concerning their "performances".


Because scenegraphs should NOT reduced performance of the tri-renderer, but java3d massively reduces performance.

There are good reasons for this, but they are nothing to do with games development.

Quote:

Lastly,
Quote:

Sun specifically does not recommend Java3d for games dev

Where on earth did you found this? ...the link please

[/quote]

A response from David on people complaining that j3d was no good for games dev, or just in general response to such complaints, pointing out that j3d had a primary purpose that was not games and that it was not being resurrected for games development, even though it was being adopted under the auspices of the games group at sun, IIRC. IIRC the recommendation was (and still is) to use JOGL for games development, and j3d for the same things it was designed for: high-end visualization for chemical, construction, physics, etc industries. Basically for anyone working in laboratories who needs to visualize scientific data. I think the generic term is "sci-vis" ?

Maybe I misunderstood the comment, and I certainly don't remember the exact words, but I'm sure that was the gist of it. David was keen to work with xith3D rather than compete with it, and felt there might be much that could be shared now, assuming compatible licenses, but was makign clear that j3d ultimately was going in a different direction, i.e. decisions are not made about j3d for games dev reasons.

Share this post


Link to post
Share on other sites

...if you wanted so much "performances", you should stick to c++ and access to open GL directly. However, i suppose you won't. And why? Because java feels more comfortable and it is worth sacrifying a notch of "performance".
For the same reason i stick to J3D, i feel comfortable with it and its performances are ok to me. And in the case i would want more, or would do some pro game, then i would directly go to c# with DX or something like this.
Performances are not the holy grail. If it was, we would still be programming in assembler.

I suppose you know "Flying Guns", doesn't it run well? So it's ok for games like this, no need to go away.

Anyway, use the api you want, JOGL is certainly a great api, but J3D is totally ok either. The first is raw performances, the other is higher leveled stucture along with its small overhead.

Share this post


Link to post
Share on other sites
As soon as somebody is asking a question about Java3D here, it usually won't be answered. People are shouting "xith" and "jme" instead. IF these APIs are so great for making games, then where are the games written with them? I don't know of any complete (or almost) game which has been written using xith or jme. However, i do know some games written in Java3D. When looking at them, you know what to expect. xith and jme still have to prove themselfs as suitable solutions.

Share this post


Link to post
Share on other sites
My personal suggestion: Only use Java 3D if you don't mind the fact that there are a lot of things that it doesn't support that it should, e.g., set operations. Honestly, Java 3D isn't bad, per se, it's just that it's not really the best API to use for games. Honestly, I'd only really ever use it for visualization applications, as opposed to interactive 3D environments.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!