[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-2d-dev
Subject:    Re: [OpenJDK 2D-Dev] [11] Upgrade to Marlin renderer 0.9.1
From:       Laurent_Bourgès <bourges.laurent () gmail ! com>
Date:       2018-02-21 20:14:17
Message-ID: CAKjRUT5NdFuUWsUN9_=D45qQ=KxWUdD3fBFgtDSRJxdCcMgFdQ () mail ! gmail ! com
[Download RAW message or body]

Phil,
Will you have some time soon to have a look ?

It fixes dashing performance definitively and dash error accumulation too.

Laurent

Le 15 f=C3=A9vr. 2018 6:30 PM, "Laurent Bourg=C3=A8s" <bourges.laurent@gmai=
l.com> a
=C3=A9crit :

> Hi,
>
> Please review this large patch providing Marlin 0.9.1 for JDK 11:
>
> JBS: to be created asap
> webrev: http://cr.openjdk.java.net/~lbourges/marlin/marlin-091.0/
>
> Changes:
> - *ArrayCache: removed clean flag and usage of
> jdk.internal.UNSAFE.allocateUninitializedArray()
> - (D)Curve: added support for lines (curve type 4) + new methods x/y
> Points to compute intersections on clip edges
> - (D)Dasher: use new CurveBasicMonotonizer & CurveClipSplitter to perform
> clipping in Dasher that uses skipLen() to compute properly the dash phase=
 &
> state
> - (D)Helpers: refined precision in cubicRootsInAB (float variant) + add
> fastXXXLen() to quickly estimate curve length from control points
>       moved findSubdivPoints() from (D)Stroker + added findClipPoints() t=
o
> determine t values corresponding to curve intersections with the clip edg=
es
> + added subdivideLineAt() to subdivide line segments
> - (D)MarlinRenderingEngine: disable stroker clipping if dasher clipping
> enabled (2nd clipping is counter-productive) + initialize new path
> simplifier if enabled (disabled by default) + log new settings
> - (D)Renderer: refined [quad/cubic]BreakIntoLinesAndAdd loops to enhance
> accuracy (smaller error related to 2nd ddx/y) with asymetric supixel coun=
ts
> - (D)Stroker: use new CurveBasicMonotonizer & CurveClipSplitter (code
> refactoring)
> - (D)TransformingPathConsumer2D: use CurveClipSplitter in PathClipFilter
> to clip filled shapes overlapping clipping edges
>             added CurveClipSplitter that subdivides curves (line, quad,
> cubic) at clip intersections (+ small padding to avoid precision issues)
>             added CurveBasicMonotonizer to monotonize curves (before in
> Stroker) to make it on initial curve in Dasher (more efficient than for a=
ll
> dashes)
> - (D)PathSimplifier: new basic path clipper (disabled by default) ignorin=
g
> too small segments (radial distance threshold)
> - ClipShapeTest: improved test to use a small tolerance as clipped curves
> (at clip edges) has minor impact on computed offsets for stroked shapes a=
nd
> on dash positions: overall quality is improved as previously larger curve=
s
> had more accumulated error on either dashes or stroke offsets
>
> Build & jtreg tests: OK
>
> Cheers,
> Laurent
>

[Attachment #3 (text/html)]

<div dir="auto">Phil,<div dir="auto">Will you have some time soon to have a look \
?</div><div dir="auto"><br></div><div dir="auto">It fixes dashing performance \
definitively and dash error accumulation too.</div><div dir="auto"><br></div><div \
dir="auto">Laurent</div></div><div class="gmail_extra"><br><div \
class="gmail_quote">Le  15 févr. 2018 6:30 PM, &quot;Laurent Bourgès&quot; &lt;<a \
href="mailto:bourges.laurent@gmail.com">bourges.laurent@gmail.com</a>&gt; a écrit  \
:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 \
.8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div \
dir="auto">Hi,<br><br>Please review this large patch providing Marlin 0.9.1 for JDK \
11:<br><br>JBS: to be created asap<br>webrev: <a \
href="http://cr.openjdk.java.net/~lbourges/marlin/marlin-091.0/" \
target="_blank">http://cr.openjdk.java.net/~lb<wbr>ourges/marlin/marlin-091.0/</a><br><br>Changes:<br>- \
*ArrayCache: removed clean flag and usage of \
jdk.internal.UNSAFE.allocateUn<wbr>initializedArray()<br>- (D)Curve: added support \
for lines (curve type 4) + new methods x/y Points to compute intersections on clip \
edges<br>- (D)Dasher: use new CurveBasicMonotonizer &amp; CurveClipSplitter to \
perform clipping in Dasher that uses skipLen() to compute properly the dash phase \
&amp; state<br>- (D)Helpers: refined precision in cubicRootsInAB (float variant) + \
add fastXXXLen() to quickly estimate curve length from control points<br>           \
moved findSubdivPoints() from (D)Stroker + added findClipPoints() to determine t \
values corresponding to curve intersections with the clip edges + added \
subdivideLineAt() to subdivide line segments<br>- (D)MarlinRenderingEngine: disable \
stroker clipping if dasher clipping enabled (2nd clipping is counter-productive) + \
initialize new path simplifier if enabled (disabled by default) + log new \
settings<br>- (D)Renderer: refined [quad/cubic]BreakIntoLinesAndA<wbr>dd loops to \
enhance accuracy (smaller error related to 2nd ddx/y) with asymetric supixel \
counts<br>- (D)Stroker: use new CurveBasicMonotonizer &amp; CurveClipSplitter (code \
refactoring)<br>- (D)TransformingPathConsumer2D: use CurveClipSplitter in \
PathClipFilter to clip filled shapes overlapping clipping edges <br>                  \
added CurveClipSplitter that subdivides curves (line, quad, cubic) at clip \
intersections (+ small padding to avoid precision issues)<br>                       \
added CurveBasicMonotonizer to monotonize curves (before in Stroker) to make it on \
initial curve in Dasher (more efficient than for all dashes)<br>- (D)PathSimplifier: \
new basic path clipper (disabled by default) ignoring too small segments (radial \
distance threshold)<br>- ClipShapeTest: improved test to use a small tolerance as \
clipped curves (at clip edges) has minor impact on computed offsets for stroked \
shapes and on dash positions: overall quality is improved as previously larger curves \
had more accumulated error on either dashes or stroke offsets</div><div \
dir="auto"><br></div><div>Build &amp; jtreg tests: OK<br></div><div \
dir="auto"><br>Cheers,<br>Laurent</div></div> </blockquote></div></div>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic