< prev index next >

src/java.desktop/share/classes/sun/java2d/marlin/DRendererContext.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 29,38 **** --- 29,40 ---- import java.lang.ref.WeakReference; import java.util.concurrent.atomic.AtomicInteger; import sun.java2d.ReentrantContext; import sun.java2d.marlin.ArrayCacheConst.CacheStats; import sun.java2d.marlin.DMarlinRenderingEngine.NormalizingPathIterator; + import sun.java2d.marlin.DTransformingPathConsumer2D.CurveBasicMonotonizer; + import sun.java2d.marlin.DTransformingPathConsumer2D.CurveClipSplitter; /** * This class is a renderer context dedicated to a single thread */ final class DRendererContext extends ReentrantContext implements IRendererContext {
*** 68,77 **** --- 70,81 ---- private WeakReference<Path2D.Double> refPath2D = null; final DRenderer renderer; final DStroker stroker; // Simplifies out collinear lines final DCollinearSimplifier simplifier = new DCollinearSimplifier(); + // Simplifies path + final DPathSimplifier pathSimplifier = new DPathSimplifier(); final DDasher dasher; final MarlinTileGenerator ptg; final MarlinCache cache; // flag indicating the shape is stroked (1) or filled (0) int stroking = 0;
*** 79,88 **** --- 83,96 ---- boolean doClip = false; // flag indicating if the path is closed or not (in advance) to handle properly caps boolean closedPath = false; // clip rectangle (ymin, ymax, xmin, xmax): final double[] clipRect = new double[4]; + // CurveBasicMonotonizer instance + final CurveBasicMonotonizer monotonizer; + // CurveClipSplitter instance + final CurveClipSplitter curveClipSplitter; // Array caches: /* clean int[] cache (zero-filled) = 5 refs */ private final IntArrayCache cleanIntCache = new IntArrayCache(true, 5); /* dirty int[] cache = 5 refs */
*** 122,131 **** --- 130,143 ---- // NormalizingPathIterator instances: nPCPathIterator = new NormalizingPathIterator.NearestPixelCenter(double6); nPQPathIterator = new NormalizingPathIterator.NearestPixelQuarter(double6); + // curve monotonizer & clip subdivider (before transformerPC2D init) + monotonizer = new CurveBasicMonotonizer(this); + curveClipSplitter = new CurveClipSplitter(this); + // MarlinRenderingEngine.TransformingPathConsumer2D transformerPC2D = new DTransformingPathConsumer2D(this); // Renderer: cache = new MarlinCache(this);
< prev index next >