Early reports on JavaFX 2 are in.

Its in private beta ATM.

[quote]Oracle has kicked off a comprehensive beta program with the JavaFX 2.0 Early Access release. Members of the JavaFX Partner Program have been invited to evaluate the software first, and a Public Beta is planned by the end of the first half of 2011. Participants will have the opportunity to provide feedback through multiple channels, including surveys, participation in focus group sessions, and discussions with key members of the JavaFX product team.
[/quote]
You can sign up here to be alerted once its available.

Hey Guys,

I’m glad to see some excitement about javafx 2. My name is Joe and I am one of the main engineers working on Prism. I’ll be looking to spend some more time on these forums to hopefully get a sense of what you guys are looking for or don’t like about what we are doing. Understand we are doing the best we can to get you the best java apis possible.

To clear up some things (as best I can without spilling the beans)…

[quote]Thank goodness they chucked out the pointless fx script for regular java syntax.
[/quote]
I personally think fx script was great. You could do a lot of neat things in that language that are verbose to do in Java.

[quote]Sounds like javafx 2 is just a lighter weight java with a new graphics backend, chucking out the bloat of awt, swing and java 2d. Yay!
[/quote]
That is a fairly accurate statement. Prism is very j2d esque in the sense that the shaders accelerate a lot of 2D paths. It is not trivial however to hardware accelerate every render path, but it is something we are working on doing.

[quote]I hope JavaFX 2 works like Flash, but you can still run 3D on it
[/quote]
I am working day and night for this to become a reality SOME day. full 3d support wont be in 2.0, but the future looks promising :wink: :wink: ;).

[quote]I hope it will be possible to use JavaFX 2 with AWT-less native windowing system provided by Java bindings of OpenGL (JOGL, LWJGL).
It might not be needed, Im sure it will contain its own way of handling 3D.
[/quote]
Yep, that is accurate.

[quote]I don’t want to rely on Java3D and I prefer using tougher scenegraphs like Ardor3D, JMonkeyEngine, …
[/quote]
I can assure you that Prism will stand toe to toe with those you just mentioned. Keep in mind this will be the first real release with Prism support, just give us time.

[quote]Prism is built on DirectX, OpenGL and has a software fallback. I don’t think you will have direct access to what’s under Prism. But now that its a standalone Java library I’m sure someone will hack it.
[/quote]
the stuff under prism is not useful on its own to developers. It’s the combination of prism with the scenegraph that makes it so powerful.

[quote]Well, maybe that’ll be possible, too, but I think that LWJGL/JOGL would have to adapt to use JavaFX’s windowing, if some direct access to it is provided.
[/quote]
If you have to resort to using JOGL, then we have failed. The idea is that the JavaFX api’s provide you with enough stuff. Granted, for a full 3d game, we aren’t there yet.

[quote]Actually I would like to use JavaFX only for its 2D GUI elements and another scenegraph instead of porting any code to Prism.
[/quote]
Interesting, but I don’t see us being able to support this in the general form. I know that dev’s have been asking for swing interoperability for a while.

[quote]I believe Oracle would have to do the same with JavaFX (expose the OpenGL pipeline) in order for the integration to be possible.
[/quote]
I think others can answer this for you. remember prism implements javafx on ogl and d3d. java + ogl = ???
As for integration, 2.0 will not have this, and I kind of address this point earlier, if you feel like you have to resort to using jogl, we have failed.

[quote]Lol, no just realistic. The java marketing machine has been a big one for over promise under deliver
[/quote]
Ouch, that stings! I shouldnt comment on this, but i hope we can meet your expectations. :smiley:

[quote]How can I get JavaFX 2 EA?
[/quote]
Correct about it being in private beta. You can check out our release plans I think?

Ayways, I better keep my mouth shut as to not get in trouble! ;D

I will be attending GDC next week, if any of you are interested in JavaFX development and are going. lemme know!

Lastly, I can speak for all the developers in saying that we thrive off of your enthusiasm. The applause we got for our J1 Demos in the keynote was so cool! We really do appreciate it.

And… Notch… I will be finding you…

oh nice, that actually sounds pretty cool.

JavaFX 1.x greatest failure IMO was that the end user experience was horrid, it took too long to start and was too heavyweight to be usable for any fast games (like a shmup).

Initially I don’t think it needs to be feature full, just something that is fast (enough for games) and have great usability for end users (meaning that unaware users shouldn’t be able to tell that its a plugin due to how smooth it works). Just look at flash, pretty crap for anything performance intensive but just works so well.

If its anything like Unity3D then I think you’ve nailed what’s required for javafx to get back in the game.

Looking forward to how it turns out.

Thanks for answering some questions JFXJoe. Sounds like JavaFx is heading in the right direction.

[quote]If you have to resort to using JOGL, then we have failed. The idea is that the JavaFX api’s provide you with enough stuff. Granted, for a full 3d game, we aren’t there yet.
[/quote]
So you trying to make prism just as powerful as the current OpenGL libraries?

[quote]I personally think fx script was great. You could do a lot of neat things in that language that are verbose to do in Java.
[/quote]
Still don’t know why the language couldn’t of been officially supported. But still have the library able to be used by Java and JavaFX Script. I personally liked coding in it.

[quote]And… Notch… I will be finding you…
[/quote]
MinecraftFx? :stuck_out_tongue:

Is there any up to date demo videos on JavaFx 2 online?

[quote]Initially I don’t think it needs to be feature full, just something that is fast (enough for games) and has great usability for end users.
[/quote]
I think everyone will agree to that. It has to have really good usability. The current JavaFX front page still freezes(the whole page) when the JavaFX loads.
Fast load up and instant user friendly loading screens is the key.

[quote][quote]Well, maybe that’ll be possible, too, but I think that LWJGL/JOGL would have to adapt to use JavaFX’s windowing, if some direct access to it is provided.
[/quote]
If you have to resort to using JOGL, then we have failed. The idea is that the JavaFX api’s provide you with enough stuff. Granted, for a full 3d game, we aren’t there yet.
[/quote]
I prefer the ‘toolbox’ approach (like how those CLI utilities work on unix/linux)… everybody tries to create a piece of software that excels at one specific purpose, leaving the rest for other (embedded) utilities. This stems from the assumption that nobody can successfully write an application that does everything correct and supports everything everybody ever wants.

It would be a major pro if you could mix and match your own renderer and JavaFX, simply because JavaFX will never (at least not in a timely manner) provide us with “enough stuff” or simply because we want to have the choice to pick JavaFX for 2D and some homegrown/specialized engine for 3D.

That, and we want progress updates :slight_smile:

I feel somewhat bemused by all this hype - I’ve yet to see a javafx demo that actually worked smoothly and provided something interesting that I couldn’t do better with regular java and opengl.

Are there some demos somewhere that I’ve missed? Ones where the user experience doesn’t suck?

@Joe,

Hi, and welcome to the javagaming forum.

While Prism support for D3D and OpenGL, means Prism will have its own API rather than a thin layer over openGL, will we be able to directly push triangles in 3D? For 3D games, I’m more interested in data-structures similar to those used in Quake, rather than scene-graphs, because the portalisation lends itself to AI path finding based on A* searches.

From Richard Bair’s podcast, I gather the new 3D stuff will probably surface in JavaFx2.1. I assume the APIs will stablise sometime before then.

[quote]JavaFX 1.x greatest failure IMO was that the end user experience was horrid, it took too long to start and was too heavyweight to be usable for any fast games (like a shmup).
[/quote]
You will notice a huge leap in performance with prism.

[quote]Initially I don’t think it needs to be feature full, just something that is fast (enough for games) and have great usability for end users (meaning that unaware users shouldn’t be able to tell that its a plugin due to how smooth it works). Just look at flash, pretty crap for anything performance intensive but just works so well.
[/quote]
i agree

[quote]If its anything like Unity3D then I think you’ve nailed what’s required for javafx to get back in the game.
[/quote]
I personally Agree, but you have to understand that javafx is not just for games =(

[quote]Is there any up to date demo videos on JavaFx 2 online?
[/quote]
Soon… keep an eye out.

[quote]MinecraftFx?
[/quote]
It is not quiiiiteeeee possible to do minecraft in fx.

[quote]So you trying to make prism just as powerful as the current OpenGL libraries?
[/quote]
No. We are trying to make it so you don’t need to refer to it as “OpenGL libraries”. Think of unity.

[quote]I feel somewhat bemused by all this hype - I’ve yet to see a javafx demo that actually worked smoothly and provided something interesting that I couldn’t do better with regular java and opengl
[/quote]
not sure i can link anything yet… but search youtube for JavaFX 2010 javaone keynote. I was on the team that wrote those demos. come on… that isn’t interesting? We managed to improve upon air hockey after the fact.

[quote]I prefer the ‘toolbox’ approach (like how those CLI utilities work on unix/linux)… everybody tries to create a piece of software that excels at one specific purpose, leaving the rest for other (embedded) utilities. This stems from the assumption that nobody can successfully write an application that does everything correct and supports everything everybody ever wants.

It would be a major pro if you could mix and match your own renderer and JavaFX, simply because JavaFX will never (at least not in a timely manner) provide us with “enough stuff” or simply because we want to have the choice to pick JavaFX for 2D and some homegrown/specialized engine for 3D.

That, and we want progress updates
[/quote]
As i said, i think providing interoperability in general is not going to work. Never say never :wink:

I will communicate as much as i can without getting in trouble.

[quote]From Richard Bair’s podcast, I gather the new 3D stuff will probably surface in JavaFx2.1. I assume the APIs will stablise sometime before then.
[/quote]
This is accurate, however, 2.0 will be a good basis for prototyping these things. For example, A* in our scenegraph would be a FANTASTIC test, Maybe with thousands of cubes. In fact, maybe EA worthy.

I’ve done a bit of digging and found an article which suggested that work on Java 3D was stopped in favour of adding 3D capability to JavaFx. Then back in 2008 Sun published a demo that contained a library scenario3d which appears to be an early version of Scene Graph 3D (SG3D), a technology intended for JavaFx.

So I believe the JavaFx1.3 scene graph will be extended to 3D in JavaFx2.1, looking somewhat similar to Java3D, but updated to fit in with the design of the current JavaFx 2D scenegraph.

So, to get pathfinding, one could implement brush and portal based data structures and then “render” them into a scene graph for display rather than projecting them directly. Perhaps one might only “render” a subset of the world into the scene graph, based on current player position, for larger worlds. That really depends on how big the world is and how good the scene graph is at culling hidden objects. How many objects can one put in a Prism backed scene graph on a modern PC and still get a reasonable framerate?

The drawback to this approach would be garbage collection, when a scenegraph is discarded and a new one is built. Maybe one could use object pools, although this would depend on how objects are created in SG3D. This could be quite interesting. One could use a portal based priority queue to identify geometry that should be displayed, then each of those data structures could contain a SG3D object. When a new scene graph is created, geometry that already has a SG3D peer could retain it, whilst new SG3D peers could be created for geometry that has just come into view. There would also need to be a way to gather up all the peers that are no longer being used and return them to an object pool.

I’m also wondering how the overlay is to be drawn, since there isn’t any AWT.

Cool stuff Joe, thanks for the info. I’m really excited about your work. So glad to hear that there’s a graphics dude working on java at Oracle 8)

There’s so much uncertainty about what the future is for java on the desktop so to have you answering our questions here is fantastic.

I don’t know what Prism is, but what I hope it will provide is:

  1. access to Direct3D (there’s no D3D binding in java)
  2. an API that abstracts the differences between OGL and D3D but is still fast and flexible.

The closer it is to the metal the better. To be honest, a scenegraph over the top of D3D sounds unnecessary and will probably just thwart performance. It’s really the D3D part which is exciting. Everyone here likes to make their own scenegraphs.

But it sounds like the JavaFX scenegraph is already in. My queston is, will it be possible to use Prism as a minimal binding over D3D and OGL without using the scenegraph? For example, can OGL/D3D be used with DisplayLists or VBO’s, ie without ‘immediate mode’ rendering? Sounds like this is not the case if you couldn’t do a minecraft-like game in it.

There is some experimental 3D support in JavaFx1.3, which appears to have gone mainstream with JavaFx2.0.
I found this article on doing a calendar as a 3D textured cube
JavaFx1.3 3D Calendar

@Joe: Is the 3D support in the JavaFx2.0 release the same as the experimental conditional support in JavaFx1.3?

I also looked at the JavaOne Demos

The air hockey game had ‘1000’s of nodes’, whilst the video ball demo had in excess of ‘15,000 nodes’.
I think the shapes on these nodes were basic cubes, rather than complex Shape3D’s (assuming these will be in the JavaFx2.1 API?).
Wonder how many nodes one can have with complex shapes comprising many triangles.

@Joe: Will there be Shape3D and all the underlying Geometry classes as in Java3D?

I’ve noticed that the Unreal Engine renders into Dynamic Scene Graphs -I think there’s some scope here for something interesting.

@Joe: Sorry we’re bombarding you with questions, but we’ve been left in the dark and would really like to know what to expect, so we can plan for the future. What about the SlimShady project? Is its development ongoing? It was meant to be better than prism for hardware acceleration, wasn’t it?

for all we know, javafx 2.0 could actually be the SlimShady project :slight_smile:

Phew okay, lots of questions…

Before I answer, let me say a bit more about myself. I graduated from Sonoma State in 2008 and I joined Sun in early 2009 to write shader fastpaths for prism. My focus in University and after was Computer Graphics and i had worked at a couple of places before joining Sun. If I were to have a specialty it would be Lighting/Modern Shader pipelines. Anyways, at the time I joined JavaFX 1.2 was just about to come out.

Since then I have written many shaders/features/demos using JavaFX/Prism for releases/JavaOne and i also wrote the binding API for PhysX 8).

So, lets see what i can answer… Keep in mind if I avoid answering a question its not because I don’t want to lol.

[quote]will it be possible to use Prism as a minimal binding over D3D and OGL without using the scenegraph? For example, can OGL/D3D be used with DisplayLists or VBO’s, ie without ‘immediate mode’ rendering? Sounds like this is not the case if you couldn’t do a minecraft-like game in it.
[/quote]
Number one reason why there is no minecraftfx, no lighting engine. minecraft consists of all cubes… which you have seen many of in FX recently. How many cubes can you have in JFX? good question. With Cube Primitives this will be higher, since currently cubes consist of 6 3d transformed rects/mediaviews/imageviews in a group.

As for the binding stuff… this is a question to ask Rich who is one of our Architects.

[quote]There is some experimental 3D support in JavaFx1.3, which appears to have gone mainstream with JavaFx2.0.
[/quote]
Ah yes, Jim Weavers stuff is pretty awesome. He is doing a lot of the 3D Calc on his own though. What you saw before that is directly from us was 3d transforms/transitions, and that is being included in the next release.

[quote]Wonder how many nodes one can have with complex shapes comprising many triangles.
[/quote]
I am dieing to figure this out myself. Stay tuned.

[quote]Will there be Shape3D and all the underlying Geometry classes as in Java3D?
[/quote]
Our graphics lead is from the Java3D project, and he is great. I can imagine we will take what we have learned from java3d and use that to make JavaFX better (we already have).

[quote]I’ve noticed that the Unreal Engine renders into Dynamic Scene Graphs -I think there’s some scope here for something interesting.
[/quote]
That does sound interesting…

[quote]but we’ve been left in the dark and would really like to know what to expect, so we can plan for the future. What about the SlimShady project? Is its development ongoing? It was meant to be better than prism for hardware acceleration, wasn’t it?
[/quote]
We don’t mean to leave anyone in the dark. Honestly, Oracle has been treating JavaFX extremely well. I can speak for all of the devs in saying that we feel we have been well received, and well directed. All of us believe in the development community of Java… Slim Shady != Prism… but like Java3D, we have learned a ton from them, etc.

As for the binding stuff… this is a question to ask Rich who is one of our Architects.
[/quote]
Thanks for the answer. Well if you could ask Rich that would be fantastisch :slight_smile:

Its not a matter of me asking… its a matter of me not being able to speak on that topic.

Can you tell us anything about the Slim Shady project or cubecase? or is those projects dead?

@Joe

Thanks for answering our questions. I’ve now got a much better idea of where things are going.

@zammbi

I spotted a video on youtube about slimshady from about 6 months ago. It looked pretty good

Performance Musings

The video wall had 1300 cubes, each with 6 mediaviews, so we have 7800 mediaviews (although at least half these are backfacing at any one time. There’s probably a couple hundred more in the video ball and a 100 or so rects in the ramps; say at least 8000 quads of various types. There’s 15,000 nodes; say 8000 linked to quads, a further 1300 or so linked to cubes and a few 100 above those. Not quite 15,000 nodes. Maybe there are more quads making up the background chequer pattern. Can’t really tell what the framerate was; 60Hz was mentioned earlier in the presentation, but this might apply to any of the demos. There’s enough performance there to do something interesting in 3D so I’ll start thinking about dynamic scene graphing, with a view to targeting JavaFx2.1. A proof of concept using quads (without lighting) should be possible on JavaFx2.0, so I’ll probably try some stuff out when the public beta comes out.

Best wishes, Alan

[quote]@zammbi

I spotted a video on youtube about slimshady from about 6 months ago. It looked pretty good


[/quote]
Yeah I saw those. Videos look very cool. I’m just wondering if its still part of Oracle, if so how does it fit in with JavaFX 2. The editor looks cool. Is that the JavaFX editor we been waiting for?

WRT: Unreal - Dynamic scene graphs. What Tim is calling a DSG is really a portal system. So at render time, a scene graph like structure is built from the “current” cell and all visible portals (potential recursive for mirrors, teleporters, etc.).