[OpenJDK 2D-Dev] Openjdk java2d rasterizer JEP for pisces (marlin) enhancements ?

Laurent Bourgès bourges.laurent at gmail.com
Tue Feb 24 14:51:09 UTC 2015


Phil,

I asked several times how to contribute back marlin to openjdk since may
>> 2014... as pisces patches ? or as an alternative renderer ?
>>
>>
> As I've asked for a long time, a webrev you create against openJDK is what
> I'd like to see.
> I can't assess what a delta it would be against pisces without that.
>

Do you want me to send you asap a webrev between JDK9 pisces and latest
marlin (0.4.5) to let you see that delta ?


> But I would suppose its reached the point where its such a large delta that
> side-by-side alternate renderer is the way to go for now.
>

Or as you proposed, do you prefer a webrev as a standalone renderer
(sun.java2d.marlin) ?

I propose to create for now a git branch "openjdk" to prepare the new
"standalone renderer" variant.


> If you grant me rights to push code into the graphics rasterizer project,
>> I would push the marlin source code to let you study it and test it with
>> all necessary test suites.
>>
>>
> That is what Dalibor and others recommended and have been working to help
> you with.


This is in progress, thanks.


> > Does it alter any behaviours or touch any code that does not involve
>> > the marlin code path ?
>>
>> I modified the the sun.java2d.pipe.AAShapePipe classes (tile cache) and
>> added the awt.geom.FastPath2d to trim and clone paths efficiently
>> (createStrokedShape).
>> These changes can be considered minor and trivial (may be optional).
>>
>>
> FastPath2D would be public API. Perhaps that should be a separate
> discussion
>

FastPath2D is only a improvement of the Path2D class to trim arrays in the
clone() method but there is another solution: provide a new Path2D
constructor with given data arrays.
I agree it is another topic but really used by marlin to avoid too many
array resizing.


> Lets be clear. We'd love this stuff if its as good as we are told but we do
> not have the time to be more proactive on this.
>

Great !


> Also we cannot legally "grab" this stuff   anyway no matter how much you
> say its OK. You need to contribute it into OpenJDK by creating the webrev
> and submitting it.
>

Ok, I have to submit a webrev.

There is two marlin variants:
- marlin 0.4.5
- marlin 0.5.5 using Unsafe for array allocation and random access to store
edge data as struct [float + int]

Note: marlin 0.5.5 is 10% faster in my benchmarks.

What variant do you prefer ?


> So
> 1. Work with Dalibor to get the rasteriser project have a forest at
> http://hg.openjdk.java.net/
> 2. Integrate your marlin code there in  way that co-exists with pisces and
> does not
> introduce any new APIs
> 3. We will then be able to more easily create builds to ask SQE run tests
> against it
> and so forth.
> 4. It then becomes much easier to see the path into putting it into the
> main repo.
>

Ok, that plan looks good.

I think step 2 will need some work (refactoring, code cleanup) in
collaboration with you & clemens ...

Cheers,
Laurent
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/2d-dev/attachments/20150224/9b87b2ff/attachment.html>


More information about the 2d-dev mailing list