What’s New? A lot! Oculus for Java 4.1 includes support for mobile devices, new animation libraries, and a new and improved rendering architecture, in addition to other enhancements.
New Smartphone and Linux Support
Oculus for Java now supports deployment to mobile devices with Android or Java ME, extending the same powerful cross-platform desktop capabilities to handheld devices using a single API. OpenGL support has also been added for Linux based desktop computers.
Android
Deployment to Google’s Android mobile device platform is now supported, with OpenGL ES based graphics acceleration.
Java ME
Deployment to base level Java ME is also now supported, without requirements for specialized and rare JSR’s.
Linux
Support for Linux has been extended to include OpenGL based rendering in addition to the existing Oculus Software 3D rendering.
New Rendering Architecture
In order to support seamless deployment to multiple mobile and desktop environments in the best way possible, it was finally time to break our tradition of maintaining 100% backwards compatibility and make a small set of revisions to the API. These architectural improvements and their associated API changes bring significant benefits at the cost of a small one time effort to port applications.
Benefits
The new rendering architecture provides significant advantages for current and future applications, including:
-
Many Devices, One Renderer
Oculus solutions for desktop, web and mobile platforms using a single core API, with only two simple classes required to integrate the application into different environments.
-
Improved Dual Core Performance
Take better advantage of multi-core processors with improved render thread transactions. Dual core systems have become a standard in new desktop computers, and wide-spread emergence for mobile devices is expected in the coming year.
-
Improved Canvas Flexibility, Extensibility
Canvas abstractions allow for greater flexibility in what the scene is being rendered to, without some of the awkwardness of the previous architecture. Canvas options include textures as well as lightweight and heavyweight platform-specific windows.
-
Shared Rendering Options
Renderers can be shared between certain canvases, such as swing components, resulting in a more lightweight application architecture appropriate for certain situations. As another example, Rendered Textures now share a renderer with the context that displays them for greater efficiency.
Overview
The new rendering architecture separates certain functional roles previously bundled up primarily with the Viewer, and breaks them down cleanly into four classes.
Vizlet
Vizlet is an interface that represents the top-most context in Oculus for Java. Vizlet implementations are responsible for life cycle, resource, and license management, as well as provided access to the platform event queue. Vizlet is implemented by an Applet class for web deployment, a Midlet for Java ME deployment, and an Activity for Android deployment. An implementation of Vizlet now exists for desktop deployment as well.
Viewer
The Viewer maintains the primary function that it had previously, as the top-level construct representing what is being rendered, and with what attributes. The roles of canvas and renderer have been extracted from Viewer. In addition, Render Settings have also been extracted and grouped together into a single class in order to streamline support for compatibility settings and on-the-fly temporary speed versus quality tradeoffs.
Canvas
The Canvas interface abstracts the surface being rendered to. Implementations include textures as well as platform-specific windows. A Viewer has a one-to-one relationship with a Viewer Canvas.
Renderer
A Renderer class is responsible for rendering a Viewer to a Canvas. The renderer’s Render Engine represents the technology that will be used to render, such as OpenGL or the Oculus Software 3D renderer. A renderer may be shared between canvases in some cases where efficiency may be gained.
New Animation Framework
A new easy-to-use animation framework has been added that provides compelling animated transitions between scene states for use in applications. Using animations can be as simple as calling Viewer.build(new Transition(1f)) to animate all changes over a period of one second using a default tween. If more sophisticated animations are desired, full keyframe based animations can be set up for specific scene elements.
And More…
Additional enhancements include:
- Shape Silhouettes
- Arrowheads on Lines
- Clipping Planes
- Depth-Based Fade Effects
- Texture Sub-Updates
- Card Cached Geometry (Vertex Buffer Support)
- Scene and Scene Change Serialization
- Simple Cross-Platform XML Parsing
- Fine Build Control
- Build Events
- Render to Texture
- Asymmetric Viewing Frustums
- Face Set Enhancements
- Hi-Resolution Snapshots, Printing
- more…

