src/share/classes/sun/java2d/SurfaceData.java

Print this page

        

*** 67,76 **** --- 67,77 ---- import sun.java2d.pipe.OutlineTextRenderer; import sun.java2d.pipe.DrawImagePipe; import sun.java2d.pipe.DrawImage; import sun.awt.SunHints; import sun.awt.image.SurfaceManager; + import sun.java2d.pipe.LoopBasedPipe; /** * This class provides various pieces of information relevant to a * particular drawing surface. The information obtained from this * object describes the pixels of a particular instance of a drawing
*** 504,514 **** sg2d.fillpipe = colorPrimitives; } sg2d.textpipe = solidTextRenderer; } sg2d.shapepipe = colorPrimitives; - sg2d.loops = getRenderLoops(sg2d); // assert(sg2d.surfaceData == this); } } else if (sg2d.compositeState == sg2d.COMP_CUSTOM) { if (sg2d.antialiasHint == SunHints.INTVAL_ANTIALIAS_ON) { if (sg2d.clipState == sg2d.CLIP_SHAPE) { --- 505,514 ----
*** 601,613 **** sg2d.fillpipe = colorPrimitives; } sg2d.textpipe = getTextPipe(sg2d, false /* AA==OFF */); sg2d.shapepipe = colorPrimitives; - sg2d.loops = getRenderLoops(sg2d); // assert(sg2d.surfaceData == this); } } /* Return the text pipe to be used based on the graphics AA hint setting, * and the rest of the graphics state is compatible with these loops. * If the text AA hint is "DEFAULT", then the AA graphics hint requests --- 601,622 ---- sg2d.fillpipe = colorPrimitives; } sg2d.textpipe = getTextPipe(sg2d, false /* AA==OFF */); sg2d.shapepipe = colorPrimitives; // assert(sg2d.surfaceData == this); } + + // check for loops + if (sg2d.textpipe instanceof LoopBasedPipe || + sg2d.shapepipe instanceof LoopBasedPipe || + sg2d.fillpipe instanceof LoopBasedPipe || + sg2d.drawpipe instanceof LoopBasedPipe || + sg2d.imagepipe instanceof LoopBasedPipe) + { + sg2d.loops = getRenderLoops(sg2d); + } } /* Return the text pipe to be used based on the graphics AA hint setting, * and the rest of the graphics state is compatible with these loops. * If the text AA hint is "DEFAULT", then the AA graphics hint requests