< prev index next >

src/java.desktop/share/classes/sun/java2d/loops/MaskFill.java

Print this page
rev 55352 : JB_base_webrev

@@ -235,36 +235,48 @@
         public void MaskFill(SunGraphics2D sg2d, SurfaceData sData,
                              Composite comp,
                              int x, int y, int w, int h,
                              byte[] mask, int maskoff, int maskscan)
         {
+            if ((traceflags & TRACEPTIME) == 0) {
             tracePrimitive(target);
+            }
+            long time = System.nanoTime();
             target.MaskFill(sg2d, sData, comp, x, y, w, h,
                             mask, maskoff, maskscan);
+            tracePrimitiveTime(target, System.nanoTime() - time);
         }
 
         public void FillAAPgram(SunGraphics2D sg2d, SurfaceData sData,
                                 Composite comp,
                                 double x, double y,
                                 double dx1, double dy1,
                                 double dx2, double dy2)
         {
+            if ((traceflags & TRACEPTIME) == 0) {
             tracePrimitive(fillPgramTarget);
+            }
+            long time = System.nanoTime();
             target.FillAAPgram(sg2d, sData, comp,
                                x, y, dx1, dy1, dx2, dy2);
+            tracePrimitiveTime(fillPgramTarget, System.nanoTime() - time);
         }
 
         public void DrawAAPgram(SunGraphics2D sg2d, SurfaceData sData,
                                 Composite comp,
                                 double x, double y,
                                 double dx1, double dy1,
                                 double dx2, double dy2,
                                 double lw1, double lw2)
         {
+            if ((traceflags & TRACEPTIME) == 0) {
             tracePrimitive(drawPgramTarget);
+            }
+            long time = System.nanoTime();
             target.DrawAAPgram(sg2d, sData, comp,
                                x, y, dx1, dy1, dx2, dy2, lw1, lw2);
+            tracePrimitiveTime(drawPgramTarget, System.nanoTime() - time);
         }
 
         public boolean canDoParallelograms() {
             return target.canDoParallelograms();
         }
< prev index next >