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

Side by Side Diff: gm/yuvtorgbeffect.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/verylargebitmap.cpp ('k') | no next file » | 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 /* 2 /*
3 * Copyright 2014 Google Inc. 3 * Copyright 2014 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 // This test only works with the GPU backend. 9 // This test only works with the GPU backend.
10 10
(...skipping 20 matching lines...) Expand all
31 31
32 protected: 32 protected:
33 SkString onShortName() SK_OVERRIDE { 33 SkString onShortName() SK_OVERRIDE {
34 return SkString("yuv_to_rgb_effect"); 34 return SkString("yuv_to_rgb_effect");
35 } 35 }
36 36
37 SkISize onISize() SK_OVERRIDE { 37 SkISize onISize() SK_OVERRIDE {
38 return SkISize::Make(334, 128); 38 return SkISize::Make(334, 128);
39 } 39 }
40 40
41 uint32_t onGetFlags() const SK_OVERRIDE {
42 // This is a GPU-specific GM.
43 return kGPUOnly_Flag;
44 }
45
46 void onOnceBeforeDraw() SK_OVERRIDE { 41 void onOnceBeforeDraw() SK_OVERRIDE {
47 SkImageInfo info = SkImageInfo::MakeA8(24, 24); 42 SkImageInfo info = SkImageInfo::MakeA8(24, 24);
48 fBmp[0].allocPixels(info); 43 fBmp[0].allocPixels(info);
49 fBmp[1].allocPixels(info); 44 fBmp[1].allocPixels(info);
50 fBmp[2].allocPixels(info); 45 fBmp[2].allocPixels(info);
51 unsigned char* pixels[3]; 46 unsigned char* pixels[3];
52 for (int i = 0; i < 3; ++i) { 47 for (int i = 0; i < 3; ++i) {
53 pixels[i] = (unsigned char*)fBmp[i].getPixels(); 48 pixels[i] = (unsigned char*)fBmp[i].getPixels();
54 } 49 }
55 int color[] = {0, 85, 170}; 50 int color[] = {0, 85, 170};
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 private: 124 private:
130 SkBitmap fBmp[3]; 125 SkBitmap fBmp[3];
131 126
132 typedef GM INHERITED; 127 typedef GM INHERITED;
133 }; 128 };
134 129
135 DEF_GM( return SkNEW(YUVtoRGBEffect); ) 130 DEF_GM( return SkNEW(YUVtoRGBEffect); )
136 } 131 }
137 132
138 #endif 133 #endif
OLDNEW
« no previous file with comments | « gm/verylargebitmap.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698