Java Solaris Communities Sun Store Join SDN My Profile Why Join?
 
Bug Database
Bug Detail
Quick Lists
Top 25 Bugs
Top 25 RFE's
Recently Closed Bugs
Printable Page Printable Page


Bug Database
Bug ID: 4607536
Votes 1
Synopsis Use opengl to improve runtime performance of Swing/2D
Category java:classes_2d
Reported Against tiger
Release Fixed 1.5(tiger)
State 10-Fix Delivered, request for enhancement
Priority: 4-Low
Related Bugs 4641848
Submit Date 14-DEC-2001
Description




Improve the runtime performance of Swing and 2D , using opengl bindings. OpenGL has drivers available on many operating systems that can take advantage of hardware acceleration on the graphics card itself.

Original optional support is for Linux and Solaris.

Later addition for optional support for windows tracked separately as 5008045 OGL: add OpenGL-based pipeline for Windows
Work Around
N/A
Evaluation




This feature has been added for Tiger release

======================================================================

A baseline OpenGL pipeline for Java 2D has been putback as of 2/18/2003.  This
OpenGL pipeline is currently disabled by default, but can be enabled by
specifying the -Dsun.java2d.opengl=true system property on the command line.  A
number of requirements must be met for the pipeline to be enabled:
  - the -Dsun.java2d.opengl=true flag must be specified
  - the libGL.so library must be available and all required function symbols
    must be present
  - the GLX version must be >= 1.3
  - the OpenGL version must be >= 1.2 and the GL_ARB_imaging subset must be
    present
If any of these requirements is not met, the existing X11 pipeline will be
used.  These requirements are subject to change in the future as the
pipeline is updated (requirements will most likely be loosened so that we
support a wider variety of configurations).

This new pipeline has been extensively tested using the IFB (Expert 3D) and
IFB-lite (Expert 3D Lite) framebuffers and the Sun OpenGL for Solaris 1.3
implementation.  In theory this pipeline should work well on all modern
Sun framebuffers, as well as any video card supported by XFree86 on Linux.
However, there are some outstanding driver/library bugs that cause problems
when running Java apps with the OpenGL pipeline enabled.  We are working
closely with driver groups within Sun and at other companies (ATI, Nvidia,
etc.) to get these issues resolved.  Once these bugs are fixed, the Java 2D
OpenGL pipeline should be accelerated in hardware on a variety of video
cards, including (but not limited to):
  - Sun IFB series (Expert 3D, Expert 3D Lite, XVR-500)
  - Sun FFB3 (XVR-1000)
  - Sun IFB3 (XVR-1200)
  - Nvidia boards from the TNT series to the Radeon series
  - ATI boards in the FireGL and Radeon series
  - many other boards supported by the open source DRI project
 
This umbrella RFE to support OpenGL will be marked "fixed" since baseline
support for OpenGL is now available in Tiger.  There is still plenty of
engineering work remaining to make the pipeline perform better, to take
advantage of more OpenGL features and extensions, and so on.  Some examples
include:
  - enable OpenGL as the default pipeline for certain (modern) framebuffers
  - cache glyphs as OpenGL texture objects for increased text performance
  - allocate VolatileImages in unused backbuffer memory
  - accelerate Beziers using OpenGL primitives
  - fix XORed text rendering (causes the only known JCK failure when the
    sun.java2d.opengl=true flag is specified)
These issues will be opened as separate bugs and RFEs with "OGL: <desc>" in
the synopsis for easy tracking.
 
Note that the OpenGL libraries need not be installed on build machines in
order to build the JDK.  The necessary headers are included in the source
tree (only used to resolve GL_* constants) and the appropriate libraries are
dynamically loaded at runtime, obviating the need to statically link
libGL.so at build time.
 xxxxx@xxxxx  2003-02-18
Comments
  
  Include a link with my name & email   

Submitted On 03-JAN-2002
josgood
Speaking of OpenGL bindings...

It would have been nice if Sun, SGI, the OpenGL ARB, or all 
three, had seized the opportunity to adopt the Magician 
bindings (created by Alligator Descartes 
<alligator@symbolstone.org>) a few years ago.  At the time, 
I had the impression Sun believed Java3D and OpenGL were 
competitors.  If so, that's too bad, because they are 
different architectural layers.

There are now other "JavaGL" solutions being distributed, 
of varying quality.  If Sun does create Java bindings for 
OpenGL, please refer to the ARB's notes on this topic.



Submitted On 28-FEB-2003
filipsel
Thank you, thank you, thank you!!!!



PLEASE NOTE: JDK6 is formerly known as Project Mustang