Tag recording picture nesting bench as nonrendering.
authormtklein <mtklein@chromium.org>
Tue, 16 Sep 2014 17:12:42 +0000 (10:12 -0700)
committerCommit bot <commit-bot@chromium.org>
Tue, 16 Sep 2014 17:12:42 +0000 (10:12 -0700)
Doesn't hurt as is, but we're running it several times unneccesarily.

(I couldn't compile without removing an unused constant in that other GM...)

BUG=skia:
R=fmalita@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/570303002

bench/PictureNestingBench.cpp
gm/convexpolyeffect.cpp

index f1adb6084026d9703cae83a502425a43cbb1137c..c2848833b747a8d8afaaf09117addeb75129fe04 100644 (file)
@@ -99,7 +99,11 @@ public:
     }
 
 protected:
-    virtual void onDraw(const int loops, SkCanvas* canvas) {
+    virtual bool isSuitableFor(Backend backend) {
+        return backend == kNonRendering_Backend;
+    }
+
+    virtual void onDraw(const int loops, SkCanvas*) {
         SkIPoint canvasSize = onGetSize();
         SkPictureRecorder recorder;
 
index 0938e58db066d2337c6e4c30cd31437dfbb728f0..4f84c615d45a0df166d39dad4d97269c6ce4bcd3 100644 (file)
 
 #include "effects/GrConvexPolyEffect.h"
 
-namespace {
-extern const GrVertexAttrib kAttribs[] = {
-    {kVec2f_GrVertexAttribType, 0, kPosition_GrVertexAttribBinding},
-};
-}
-
 namespace skiagm {
 /**
  * This GM directly exercises a GrEffect that draws convex polygons.