3D Features

Skip to end of metadata
Go to start of metadata

The OpenJFX wiki has moved to https://wiki.openjdk.java.net/display/OpenJFX

Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Oct 17, 2012

    It is extremely important to support officially at least one file format. I believe Java3D did not get widespread adoption because of this point. Do not underestimate the importance of supporting a file format. Without it there is no workflow from 3D modeling software to JavaFX 3D.

    Instead of obj, maya, 3ds or blender file formats, JavaFX should support the FBX format. This is supported by almost every modeling software. It is also the format supported by the Unity game engine, which means there are enourmous number of available models to purchase or download for free (and most of these are modeled specifically to add to a real time engine/game engine), and also millions of modelers who are already using the workflow of model -> FBX -> 3D engine.

    Please reconsider the lack of a file format loader, it would be a catastrophic error not to include and officially support one.

    1. Feb 20, 2013

      I really really agree with you. This is a killer feature. It must be available. It would bring so many benefits to have this feature.

      Oracle team, please consider this if you want JavaFX to be a huge success!

  2. Oct 21, 2012

    This 3D Features is really important for me and all JavaFX Devs. I'm glad to hear about this features updates. I've been making some 3D Maker Software for JavaFX like "Scene Builder". I think JavaFX must be made highly optimized for rendering the 3D objects . I found many glitch while making this software like performance, the memory usage etc. Anyway hope in future JavaFX team will improve for the optimization and high graphics acceleration.

    I'm looking forward for the supported formats which can be imported in javafx for 3D Development.


  3. Dec 30, 2012

    In my opinion, what you propose is very difficult and is reinventing the wheel.  I think that the effort would be better spent embracing WebGL support within the WebKit based WebView.  JavaFX already embraces the official HTML5 standards and this seems to be a natural step in its evolution.

    I would think that enabling the WebGL hooks already existing in the WebKit would also be much easier to accomplish.  It's quite easy to facilitate data bindings between the WebEngine and some html content.  WebGL would bring powerful frameworks like Three.js into JavaFX. 

    I have tried to get by with Three.js rendering to a canvas, but the capabilities are very limited and the performance is about 60 times slower than a WebGL renderer.

    Rendering to HTML5 also has the benefit of easily saving JavaFX created assets as standalone html pages and I think that this follows the existing paradigm of embracing existing and emerging web standards in JavaFX.

    1. Feb 20, 2013

      Agreed, long and difficult path ahead.

      It'll only be useful to the most simplistic cases, and won't leverage 20 years of OpenGL/DirectX advances and experience.

      You will quickly run into limitations by wrapping OpenGL/DirectX into yet another scenegraph API. Expose low level API first please. Lots of third-party scenegraphs exist already for those who need more simplicity. You could even sponsor one of them as “semi-official”, like Adobe did with Away3D.

      I have an app that uses JOGL, but I can’t port it to JavaFX if it doesn’t support OpenGL, which is a real pity since JavaFX has lots of strong points (CSS GUI skinning!)

      Why not work with the JOGL team to expose OpenGL to JavaFX officially ?

  4. Jan 28, 2013

    Since 14th Nov, last year, there is no more information about 3D. Is there any information about the progress? In Java 8, there is no 3D change, and the 28th Feb there is a developer preview. Are those 3D features postposed?


    PD.- I also think that providing WebGL for the webview will be powerful (http://madebyevan.com/webgl-water/).

  5. Jan 28, 2013

    The implementation of 3D API for FX 8 is actively being developed and should be available in a FX 8 EA build soon.

  6. Jan 31, 2013

    Thanks, how can we be notified of this?  I'll watch this page. :)

    1. Feb 01, 2013

      I believe the OpenJFX alias (openjfx-dev@openjdk.java.net) might be a good place to monitor the 3D API progress. We will be sending a formal 3D API approval request to the OpenJFX alias shortly.

  7. Feb 20, 2013

    I see how we can define images using "materials" but can we define each side of a rectangle, or another 3D Object(That has sides)?  What about splitting a sphere in half and having 2 different images or affects on each?  Before using a box, I had made a cube using a rectangle builder for 6 sides, and having 6 images to create a "dice."  There seems to be a lot of new features I don't know about, so I apologize if it's specified above to which I didn't grasp it :).

  8. Feb 20, 2013

    Here's a Java 8 Lambda version of the rotation logic. 

    1. Feb 22, 2013

      Yeah I found that out last night with NEtbeansLamba8.  I thought it was super cool..  I'm new to Event Handling in JavaFX, so normally you would do event, then mouse?  I know in swing you could do a few things like implement the mouseMotionListener, or call each and override, which seems to be what this lambda is getting rid of :).  super cool!

  9. Feb 21, 2013

    There is something wrong, in the TriangleMesh there is no setPositions, but there is setPoints.

    Thanks for the example, is there any example with triangle mesh? I make sence to add a link to the example from fxexperience: http://fxexperience.com/2013/02/javafx-3d-early-access-available/.

    1. Feb 22, 2013

      Thanks for pointing this out. I have updated the code segment. The setPositions was the name used in our prototype. This name is now changed to setPoints during our API review.

      Here is a simple mesh generation program: https://wikis.oracle.com/display/OpenJDK/SimpleMeshView.java

  10. Feb 28, 2013

    Why exactly is there no set x, y, z for Box?

  11. Jul 04, 2013

    I'm trying to create an application of which one part is a Scene with 3D rendering, but the Scene should be surrounded with regular GUI elements that are not subject to the 3D camera and projection. Think of a 3D editor along the lines of Blender, for example).

    Either I'm missing something (help!) or JavaFX is limited to either a regular GUI or a 3D projected Scene, but cannot combine the two. If that is the case, something needs to be done about this, otherwise the 3D aspect of JavaFX will be severely limited in its use. Please prove me wrong, thanks!

    1. Jul 05, 2013

      There are a few things you can do.

      1.  I believe there is something called "setDepthTest(boolean);" for Nodes, which means you can set it to false to display certain 2D nodes.

      BUT in my personal opinion, I would check out "SubScene" which is basically added to a root, as a child(or could possibly be the root[but why Idk :p]), and each "SubScene" has it's own Camera, so you could use 2D along those lines.

      At the top of this page it says "

      Movable cameras and SubScene

      • Camera is now a Node
      • Camera can be added to a scene graph
      • Camera's position and aim (or orientation) is set using standard Node transform properties and methods
      • For backward compatibility, fixed camera need not be added to the scene
      • Added new properties for near & far clipping plane
      • SubScene is a special Node for scene separation
      • It can be used to render part of the Scene with different camera"

Sign up or Log in to add a comment or watch this page.

The individuals who post here are part of the extended Oracle community and they might not be employed or in any way formally affiliated with Oracle. The opinions expressed here are their own, are not necessarily reviewed in advance by anyone but the individual authors, and neither Oracle nor any other party necessarily agrees with them.