[OpenJDK 2D-Dev] X11 uniform scaled wide lines and dashed lines; STROKE_CONTROL in Pisces
james.graham at oracle.com
Mon Nov 8 11:22:18 PST 2010
Also, some things to note in the new version - things I had to "fix" not
related to performance.
In endRendering the pixel bounds of the edges needed to be computed and
passed along to the next stage. Unfortunately the code in endRendering
computed the sub-pixel bounds and then simply shifted them to get the
pixel addresses of those bounds. For the bottom and right edges, this
means that a ceiling operation was performed on the sub-pixel data, but
a floor operation was performed on the conversion to pixel addresses.
This means that the bottom few sub-pixel rows could have been sliced off
in these calculations. I restructured the calculations there to make
sure that it produced the pixel bounds of all of the subpixel rows.
Also, I use a ceil() operation on the sub-pixel values because we really
want to know what is the next sub-pixel sample row/column that we will
cross and then get the (pixel) bounds of those sample row/columns.
I think there may have been a couple of other places where the "which
pixel are we on" code got sloppy along similar lines to the endRendering
The conditions for sending the alphas for the last row changed a little.
I need to have every row visited in my AlphaConsumer because it is
cleaning out an alpha tile as it incorporates the new alphas. Thus, I
needed the logic to call "getAndClear" even if there were no alphas to
deliver. I don't think that change would have affected your version
with the PiscesCache since you can just finalize the cache when the
alphas are done and clearing the alphaRow array is irrelevant at that
final stage. The way this works may change as I continue optimizing.
On 11/8/2010 6:40 AM, Denis Lila wrote:
> Hi Jim.
>> Also, I've gotten another 20% improvement out of the design with a few
>> more tweaks. (Though I measured the 20% in the stripped down version
>> that I'm prototyping with FX so I'm not sure how much of that 20%
>> would show up through the layers of the 2D code. Overall, I've about
>> doubled the frame rates of the prototype since your first drop that you
>> checked in to the OpenJDK repository.)
> Can I see your new version?
More information about the 2d-dev