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: 6690659
Votes 0
Synopsis Simple primitives (rectangle and lines) are slow when rendered with a transform
Category java:classes_2d
Reported Against
Release Fixed 6u10(b23)
State 10-Fix Delivered, Verified, bug
Priority: 2-High
Related Bugs 6695820 , 6709823
Submit Date 18-APR-2008
Description
A short test case is attached which shows that simple transformed rectangle
fills and AA rectangles are up to 20 or more times slower than simple
untransformed rectangle fills, even on the latest hardware.  With the power
of the hardware GPUs in todays machines, there should be little, if any,
difference in the rendering speed of these primitives.

Indeed, experiments show that we can achieve near-parity for transformed and
AA rectangles and wide lines using simple variations of the D3D and OGL
FillRect primitive and a small Pixel Shader program that runs on most
graphics cards that have been common for the past 3 or 4 years.
Posted Date : 2008-04-18 07:19:15.0
Work Around
N/A
Evaluation
With a simple shader program and some new internal pipeline pathways the
performance of the following primitives can improve by a factor of around
10x depending on the hardware:

fillRect()                AA and transformed
fill(Rectangle2D) non-AA, AA, and transformed
drawRect()                AA and transformed
draw(Rectangle2D) non-AA, AA, and transformed
drawLine()                AA and transformed
draw(Line2D)      non-AA, AA, and transformed

Running tests on a 512MB nVidia 8600GT M:

With these changes the attached test case improves by a factor of about
9x to 20x for the 3 cases where AA or transforms are involved.

A very dramatic improvement can be seen in the Scenario demo DynamicDemo
which improves by the following amounts:

                      orig6u10         newshader

AA stroke/fill          6984ms           656ms   (10.6x)
AA stroke               4468ms           531ms   ( 8.4x)
AA fill                 2922ms           437ms   ( 6.7x)

non-AA stroke/fill      1656ms           656ms   ( 2.5x)
non-AA stroke            797ms           531ms   ( 1.5x)
non-AA fill             1141ms           422ms   ( 2.7x)
Posted Date : 2008-04-18 07:32:21.0
Comments
  
  Include a link with my name & email   


PLEASE NOTE: JDK6 is formerly known as Project Mustang