[OpenJDK 2D-Dev] Custom rendering engines in jk9
mandy.chung at oracle.com
Tue Apr 1 21:14:38 UTC 2014
On 4/1/14 3:09 AM, Laurent Bourgès wrote:
> In the following bug, you propose to remove the ServiceLoader in the
> RenderingEngine class:
> For now the jdk has only ductus and pisces engines but I am working on
> marlin which is an improved pisces:
> To use marlin I rely on this service loader... but maybe others too.
To use your own RenderingEngine, you will have to set the system
property -Dsun.java2d.renderer to the marlin implementation class in
addition to adding it a service configuration file, right?
> Please keep at least the factory pattern to let users choose which
> rendering engine to use at startup.
sun.java2d.pipe.RenderingEngine is not a supported API. With Jigsaw in
JDK 9, the access control rules will be extended to support
encapsulation and you won't be able to access the JDK internal APIs
(which is orthogonal to JDK-8039975.
> PS: I still hope merging my changes from marlin into jdk9 pisces in
> future to improve both performance & visual quality.
It looks like your ultimate goal is to merge your change to jdk9 and so
that won't become an issue to you.
More information about the 2d-dev