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

Side by Side Diff: samplecode/SampleFilterFuzz.cpp

Issue 234243002: Revert of Rename kPMColor_SkColorType to kN32_SkColorType. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 8 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 | « samplecode/SampleFilter.cpp ('k') | samplecode/SampleTiling.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 #include "SampleCode.h" 7 #include "SampleCode.h"
8 #include "SkBicubicImageFilter.h" 8 #include "SkBicubicImageFilter.h"
9 #include "SkBitmapDevice.h" 9 #include "SkBitmapDevice.h"
10 #include "SkBitmapSource.h" 10 #include "SkBitmapSource.h"
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 109
110 static SkDisplacementMapEffect::ChannelSelectorType make_channel_selector_type() { 110 static SkDisplacementMapEffect::ChannelSelectorType make_channel_selector_type() {
111 return static_cast<SkDisplacementMapEffect::ChannelSelectorType>(R(4)+1); 111 return static_cast<SkDisplacementMapEffect::ChannelSelectorType>(R(4)+1);
112 } 112 }
113 113
114 static bool valid_for_raster_canvas(const SkImageInfo& info) { 114 static bool valid_for_raster_canvas(const SkImageInfo& info) {
115 switch (info.colorType()) { 115 switch (info.colorType()) {
116 case kAlpha_8_SkColorType: 116 case kAlpha_8_SkColorType:
117 case kRGB_565_SkColorType: 117 case kRGB_565_SkColorType:
118 return true; 118 return true;
119 case kN32_SkColorType: 119 case kPMColor_SkColorType:
120 return kPremul_SkAlphaType == info.alphaType() || 120 return kPremul_SkAlphaType == info.alphaType() ||
121 kOpaque_SkAlphaType == info.alphaType(); 121 kOpaque_SkAlphaType == info.alphaType();
122 default: 122 default:
123 break; 123 break;
124 } 124 }
125 return false; 125 return false;
126 } 126 }
127 127
128 static SkColorType rand_colortype() { 128 static SkColorType rand_colortype() {
129 return (SkColorType)R(kLastEnum_SkColorType + 1); 129 return (SkColorType)R(kLastEnum_SkColorType + 1);
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 } 427 }
428 428
429 private: 429 private:
430 typedef SkView INHERITED; 430 typedef SkView INHERITED;
431 }; 431 };
432 432
433 ////////////////////////////////////////////////////////////////////////////// 433 //////////////////////////////////////////////////////////////////////////////
434 434
435 static SkView* MyFactory() { return new ImageFilterFuzzView; } 435 static SkView* MyFactory() { return new ImageFilterFuzzView; }
436 static SkViewRegister reg(MyFactory); 436 static SkViewRegister reg(MyFactory);
OLDNEW
« no previous file with comments | « samplecode/SampleFilter.cpp ('k') | samplecode/SampleTiling.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698