java JOGL and similar resources - java

just joined this awesome siteā€¦
Ive recently been working in XNA on C#, making a library for that framework.
Ive gotten interested in java at was going to try making a similar library for java.
Thats when the problem arrived, there doesnt seem to be a standard 3d renderer on it.
Ive heard of JOGL, but it seemed to be discontinued (project inactive), and i prefet high level anyway,
Then I saw jMonkey and espresso 3D, but both seemed less efficient and less pretty then directx.
JavaFX discouraged me by saying that its for rich internet content.
My question is, which out of these are optimal. What is the technical difference between OpenGL and DirectX, are jMonkey and co. Actuallh effective? And if not is there a framework similar to XNA for java?
I only ask you name some and point me in the right direction, as this got me a bit confused after the 1 way .NET xD.
Also, as this is my first post here, feel free to correct any mistaked I may have made.

I think jmonkeyengine or jogl are probably the best choices, but it really depends on what your doing. Jogl looks like its still going but is now part of a fuller set of libraries, jogamp, which covers sound and gpgpu programming as well as graphics.
http://jogamp.org/
Jogl is essentially a java wrapper around OpenGL, so will be low level and require to write shader code in order to do anything modern. Jmonkeyengine is probably more the sort of thing you're after since it comes with a lot of prepackaged functionality (including its own IDE).

The real standard 3D API for Java -- in the sense that it's the one that Sun once considered "official" -- is Java3D, which is a scene graph API, something like Open Inventor. I never liked it much, and the level of support these days is pretty low. But it's worth considering, if only for completeness.

Related

Plotting dense 3D point clouds ( or mesh) in java

I am gonna be writing java code to plot 3D point clouds. Someone suggested me to go for java 3D libraries however it is apparently dead (this reference) and not apparently good idea go to with JMonkey either (same reference).
That link was posted in 2009 and we are in 2012.
All I want to do is to plot a dense 3D point cloud, say 5 million points, and to be able to rotate it / or zoom in real-time. I know the algorithms for rendering and stuff however I need a set of 3D java library with active community and support ( if any).
Please consider Desktop and also Web applications while suggesting me the solution.
Thanks a lot
and not apparently good idea go to with JMonkey either (same reference)
What you reference there is more than three years old, ancient in terms of technology.
jME has come back in a big way since then. jME3 is it an extraordinarily stable beta with Android support, improved physics support (both JBullet as well as a native wrapper), an SDK with scene editor, lots of user-contributed plugins, and an extremely active community.
There are a number of successful games making use of it as well, most notably Mythruna and 3079.
What you're looking to do is easily accomplished in jME and we'd invite you to come on over and try it out. http://jmonkeyengine.org
Not a scenegraph, but LWJGL offers an easy wrapper around OpenGL, so you could quite easily construct a list of quads to represent your points and setup/modify a view to display and rotate them depending on user input.
This should work in applets also to cover your web targets.
jzy3d
is what you are looking for.
Jzy3d is an open source (BSD) java library that allows a rapid display
of 3d scientific data, either surfaces, scatter plots, bar charts, and
lot of other 3d primitives. The API provides support for rich
interactive charts, with colorbars, tooltips and overlays. Axis and
chart layout can be fully customized and enhanced.
I would use JavaFX for this. It is already included in JDK 8 and the project is well alive.
Contrary to LWJGL, there is more and better documentation. Also LWJGL being a thin wrapper, will force you to learn OpenGL as soon as you need to do any transformation, and that will take you some time.
Jzy3d is a higher level API but the tutorial is not free.
JME3 is overkill and, as long as my limited experience with it taught me, you'll need to use Blender to create the model (I might be wrong).
There is a lot of documentation for JavaFX online. If you don't mind buying a book, "JavaFX for Dummies" is quite good, although basic.

Alternative to Java3D

Colleagues of mine are using Java3D for visualizing results of finite element simulations. The problem is that Java3D seems to be somehow dead, and it is a pain on OSX. This is one of the reasons we are looking for alternatives.
Quite a lot of work has gone into our current implementation based on Java3D, so the question is how much effort it would be to move away from Java3D.
JOGL is one option, but looks like a lot of work.
Has anyone suggestions for alternatives? Any experiences with such a migration?
JOGL provides a direct access to OpenGL functions. These functions are mostly low level draw functions, and you have to deal with the 'state machine' nature of OpenGL while you are programming.
Java3D abstracts this state machine. It allows you to define a tree of graphic objects, placed in a virtual scene, and rendered by a camera. The manipulation of these graphic objects is easier with such a tree structure. Then, it's up to Java3D to walk through this tree and call the OpenGL drawing functions.
This kind of library is called a scenegraph. There are many scenegraph libraries in java, some are implemented on top of JOGL. I don't have a list, but this keyword will help you in your research.
In our project, we tried 3 or 4 different libraries, but no one filled all our requirements. We ended writing our own scenegraph library (on top of JOGL).
jMonkeyEngine, Ardor3D, jPCT or Xith3D are much better options these days.
JOGL is indeed a good option. However, it's simply a wrapper library for OpenGL. That means you'll still have to do a lot of the legwork yourself. If you're comfortable with that and it suits your needs, it's not actually all that difficult. But it might be a bit time consuming and not knowing your current code-base I don't know how easy the transfer is.
You could however go for an engine which might use JOGL. Something like JMonkey Engine to purely name an example. If you look, you'll surely find some others. Have a look at those, their ease of use and their functionality to see what best suits you. They probably won't take all the work away from you, but they might make it a bit easier.
See also this Java 3D forum thread : Java3D viability questions... https://forums.oracle.com/forums/thread.jspa?threadID=2150209&tstart=15
August, InteractiveMesh
I use JOGL 2.0 (which is a low level Java binding for the OpenGL (and OpenGL-ES) API. I have recently helped someone to revive Java3D. Now, it relies only on JOGL 2.0 and it works better, especially on Mac OS X. You can find the source code here:
https://github.com/hharrison/java3d-core
Let's have fun. It is actively maintained anew ;)
P.S: I wrote a detailed article to explain how to use the very latest version of Java3D (1.6) here.

Flash animation-like 2d graphical library for C++ or Java

I'm looking for a good (hopefully free) 2d graphical library in C++, or in worst case, Java, which helps create the look and feel of Flash animations, the typical ones you can find in most flash games.
The best would be if it provided most of the features and easiness of Flash animation programming, like layers, or even collision detection, etc., without all the micromanagement of pixels typical for opengl. Of course, it can be built upon opengl...
Edit: interactivity is important, it might not been clear in the first description. So I'm not aiming just for an animation, or presentation. A good collision, gravity, etc. system is very much welcome, as are good GUI widgets.
Checkout the new ForPlay from Google.
It compiles to java, javascript, android and more.
Edit: Moved and name changed to PlayN
There is also a stackoverflow tag
Potential ideas:
Processing has been used to make some very good visualizations.... depending on what you want to do this may be a good option.
JavaFX was designed as a framework for building Rich Internet Applications (a bit like Flash). I think it has a lot of the Flash-like features you are referring to.
I don't know if this is exactly what you're looking for, but you can take a look at SFML.

Coming back to Java after a long absence; good Java game dev resources?

I've just gotten a new job and will be focusing a lot more on Java development. I figure I'll do my business stuff (Web) during the day, and then do a bit of playing after hours (Game Dev).
It's been forever since I've been active in any sort of Java game development community; is there a good central source for such information? Source demos, frameworks, books, that sort of thing?
Thanks!
IVR Avenger
You could do worse than investigate the Light Weight Java Games Library (LWJGL).
Also JOGL.
Also FengGUI for 2D interfaces in OpenGL (think a themable Quartz 2D Extreme in Java).
www.jmonkeyengine.com
a java game engine;
One thing that I liked about jmonkey is that it had decent resources for getting the project to build using several combinations of tools. I think you'll find the demos are adequate as well.
Killer Game Programming in Java by Andrew Davison
Some of the content is a few years old (but mostly still relevant) and he just added a new chapter in June, so the site is still active.
I would also take a look at Project Darkstar. The project deals with distributing actions and messages between game client(s) and game server(s), essentially dealing with client-server gaming backend. It also has a good forum for different integrations with different Java frameworks for GUI.
If you're looking at Java Applets, in my opinion, the best overall resource is Pulp Core.
This deals with the common problems you'll face with Applets, in particular with loading. In addition it abstracts you from problems like animation timers, client sound issues. The applets work without any installation other than Java - which for me is a very high requirement.
See the example game and the Bubble Mark score. I'm not affiliated with them in any way but I have delved into the source before!
Don't be put off by Java Applets. They have a bad past but the present is different. Installation is faster, startup more than acceptable, and the environments are no longer so polluted by Microsoft's deliberately bad VM. Java currently has a 75% adoption rate but for gamers you will typically get a much higher percentage (over 95% of new visitors to my gaming site have Java already installed).
Some useful resources that may help you:
This
page has a bunch of great links about animations and game tutorials.
Interactive
book by the creator of Pulp
Games
Swing and the EDT - unfortunately a
must know.
gamedev.net and devmaster.net are pretty much the two game development resources; language-agnostic, maybe leaning towards the C++ side, but it's all the same thing no matter what language you express it in.
Unfortunately those two sites just don't cut it for me. I would really like to see a GOOD game dev website. Maybe it's just me but it seems like everyone's working on their own thing and there really isn't any good central repository for, like, everything. I love the concept of gamedev.net's articles section, but many are outdated now and don't seem to be kept up. It's a shame, really. Stackoverflow is my best game dev resource right now.
Also check out the questions I've asked in the past, and my favorited questions (if you can see them). I keep a very close eye on tags related to java and/or gamedev here all the time (thus what led me to this question :) ).
Check out the java gaming forums. http://www.javagaming.org/ They are quite active, and seem to have experience developers that probably can point to the latest in javagaming tech.
Also, here are some engines I know of for 3D games.
jpct www.jpct.net small jar file and relatively fast, supports both software and hardware (OpenGL via LWJGL or JOGL) rendering. Not open source, but the developer answers questions promptly. By the way, I'm not the developer of jpct.
Also, jmonkey engine as posted before, very mature engine.
There are others like Xith3D, 3DzzD, but I would say jmonkey is the largest right now.
If you're looking into 2D content, I would say check out PulpCore or Slick 2D.

Why might gwt be getting more popular?

I've noticed a dramatic increase in GWT popularity during the past 6 months. More evidence can be seen here:
http://www.indeed.com/jobtrends?q=gwt&l=
Can someone explain the cause?
I think there are basically three reasons for this:
Organic Growth - Have you ever used GWT? I don't know about most people, but for me, none of the marketing material on the GWT site was very convincing. Then I ran into a little small personal project that required integration with Google maps and app engine. I decided to try GWT since the tools made it so easy. Using it once, even for an extremely modest project has completely changed my mind. I suspect this means there has been a lot of word of mouth propagation of the framework over the past 6 months.
Maturity - The early versions weren't used by Google all that much (little dogfooding) and were a bit rough around the edges. The latest releases seem to have solved most of the growing pain issues (though compile times are still too high, imo) and have turned it into a solid, usable framework.
Styling - They've started including a set of default skins. I think this has helped their demos to look quite a bit more impressive for recent releases, whereas some people were confused in the past by the "no-styling out of the box" approach that the project had taken.
I'd be really shocked if any of these apply outside of Java shops, though. I haven't seen GWT making inroads into non-Java environments at all, and I think their current direction makes non-Java success even more unlikely.
I would say jsight's answer is a pretty good explanation.
I have looked at Flex, Rails and GWT. All three inhabit the same space, with Flex producing Flash RIAs and GWT and Rails doing the same for HTML.
Having worked with Flex, there is a lot to like but some serious niggling problems, the main one for me being the difficulty integrating HTML into a Flex app - it's no trivial task and there are few projects that can avoid this.
GWT on the other hand is daunting initially because it's Java-based and does not come with the same kind of drag and drop editor that Flex provides in Flex Builder.
But GWT Designer (by Instantiations) is a pretty good equivalent to Flex Builder in the GWT world and for a Java programmer with Swing skills, the architecture of GWT doesn't take much figuring out.
Not to mention the sheer number of Java programmers around who can pitch GWT to their managers as a simple add-on their existing Java toolset.
Plus the Google brand doesn't hurt.
In terms of sellability within the enterprise, a Java tool is always going to be an easier sell than Actionscript or Ruby on Rails. It's hard to say for sure where things are headed but I would expect to see continued growth for all three. Everyone wants RIA these days.
i think the recent release of GAE, meaning that GWT RPC can be used for free(*), would've helped.
(*) where as before, you wouldnt be able to host a GWT app that uses RPC unless you had access to a java servlet container (or used one of the bridging libraries to run RPC off a non-java server).
I propose the Matt Raible Effect. See: http://raibledesigns.com/rd/entry/ajax_framework_analysis_results
Seriously I think the number of people that base technology stack decision on this guy's blog is significant.
Certainly there's a number of people too afraid or lazy (or whatever) to learn something different from what they're used to, so that's definitely a factor. If Java developers are anything, it's lazy, and cheap. GWT wins on those points over a lot of other RIA stuff. People that know Java and Swing don't want to learn JavaScript, C# (Silverlight), ActionScript (Flex), or JavaFX (that thing still alive?), this would require some sort of effort on their part.
It also has the zombie-like acceptance of anything Google touches. (Although personally I much prefer that than anything Apple touches, at least Google respects developer choice.)

Categories

Resources