Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(119)

Side by Side Diff: gm/dropshadowimagefilter.cpp

Issue 867963004: remove unused GM flags (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: guarded flags Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « gm/downsamplebitmap.cpp ('k') | gm/drrect.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "gm.h" 8 #include "gm.h"
9 #include "SkColorFilter.h" 9 #include "SkColorFilter.h"
10 10
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 104
105 virtual SkISize onISize() { return SkISize::Make(400, 656); } 105 virtual SkISize onISize() { return SkISize::Make(400, 656); }
106 106
107 void draw_frame(SkCanvas* canvas, const SkRect& r) { 107 void draw_frame(SkCanvas* canvas, const SkRect& r) {
108 SkPaint paint; 108 SkPaint paint;
109 paint.setStyle(SkPaint::kStroke_Style); 109 paint.setStyle(SkPaint::kStroke_Style);
110 paint.setColor(SK_ColorRED); 110 paint.setColor(SK_ColorRED);
111 canvas->drawRect(r, paint); 111 canvas->drawRect(r, paint);
112 } 112 }
113 113
114 virtual uint32_t onGetFlags() const {
115 // Because of the use of drawSprite, this test is excluded
116 // from scaled replay tests because drawSprite ignores the
117 // reciprocal scale that is applied at record time, which is
118 // the intended behavior of drawSprite.
119 return kSkipScaledReplay_Flag | kSkipTiled_Flag;
120 }
121
122 virtual void onDraw(SkCanvas* canvas) { 114 virtual void onDraw(SkCanvas* canvas) {
123 void (*drawProc[])(SkCanvas*, const SkRect&, SkImageFilter*) = { 115 void (*drawProc[])(SkCanvas*, const SkRect&, SkImageFilter*) = {
124 draw_sprite, draw_bitmap, draw_path, draw_paint, draw_text 116 draw_sprite, draw_bitmap, draw_path, draw_paint, draw_text
125 }; 117 };
126 118
127 SkAutoTUnref<SkColorFilter> cf( 119 SkAutoTUnref<SkColorFilter> cf(
128 SkColorFilter::CreateModeFilter(SK_ColorMAGENTA, SkXfermode::kSrcIn_ Mode)); 120 SkColorFilter::CreateModeFilter(SK_ColorMAGENTA, SkXfermode::kSrcIn_ Mode));
129 SkAutoTUnref<SkImageFilter> cfif(SkColorFilterImageFilter::Create(cf.get ())); 121 SkAutoTUnref<SkImageFilter> cfif(SkColorFilterImageFilter::Create(cf.get ()));
130 SkImageFilter::CropRect cropRect(SkRect::Make(SkIRect::MakeXYWH(10, 10, 44, 44)), 122 SkImageFilter::CropRect cropRect(SkRect::Make(SkIRect::MakeXYWH(10, 10, 44, 44)),
131 SkImageFilter::CropRect::kHasAll_CropEd ge); 123 SkImageFilter::CropRect::kHasAll_CropEd ge);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 } 164 }
173 165
174 private: 166 private:
175 typedef GM INHERITED; 167 typedef GM INHERITED;
176 }; 168 };
177 169
178 /////////////////////////////////////////////////////////////////////////////// 170 ///////////////////////////////////////////////////////////////////////////////
179 171
180 static skiagm::GM* MyFactory(void*) { return new DropShadowImageFilterGM; } 172 static skiagm::GM* MyFactory(void*) { return new DropShadowImageFilterGM; }
181 static skiagm::GMRegistry reg(MyFactory); 173 static skiagm::GMRegistry reg(MyFactory);
OLDNEW
« no previous file with comments | « gm/downsamplebitmap.cpp ('k') | gm/drrect.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698