-
Bug
-
Resolution: Fixed
-
P3
-
1.4.0
-
rc
-
x86
-
windows_nt
There are problems in the way that we initialize the Direct3D rendering engine
inside Java2D. Basically, we _always_ initialize Direct3D and then make
a decision later (based on runtime testing or errors) whether to actually
use D3D for rendering or not.
There are a couple of problems caused by this approach:
- Performance regression:
Some platforms (NT4 in some video card configurations) are not able to
deal with a DirectDraw surface that has been initialized to use Direct3D
as well. This is not a problem on all NT4 platforms (although no NT4
platform provides acceleration for D3D), but on those configurations where
it is a problem, we end up punting entirely on DirectDraw offscreen
surfaces, which takes us back to jdk1.3 performance.
- Crash problems:
In bug 4689178, the user cannot run any Java app without crashing due to
our use of Direct3D. The source of this bug is a card/driver/configuration
issue, but we should at least have a way for users such as this to workaround
this problem (besides knowing to install the latest video driver).
Currently, we use the sun.java2d.d3d flag to indicate whether to use d3d
for rendering, but we always initialize surfaces to be D3D-capable no matter
what the flag is set to. This causes the crash because it is not the use of
D3D but the use of a D3D surface that for some reason triggers the problem.