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

Side by Side Diff: src/effects/SkMorphologyImageFilter.cpp

Issue 227433009: Rename kPMColor_SkColorType to kN32_SkColorType. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase 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 | « src/effects/SkMatrixConvolutionImageFilter.cpp ('k') | src/effects/SkTransparentShader.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 2012 The Android Open Source Project 2 * Copyright 2012 The Android Open Source Project
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 "SkMorphologyImageFilter.h" 8 #include "SkMorphologyImageFilter.h"
9 #include "SkBitmap.h" 9 #include "SkBitmap.h"
10 #include "SkColorPriv.h" 10 #include "SkColorPriv.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 const SkBitmap& source, 142 const SkBitmap& source,
143 const Context& ctx, 143 const Context& ctx,
144 SkBitmap* dst, 144 SkBitmap* dst,
145 SkIPoint* offset) const { 145 SkIPoint* offset) const {
146 SkBitmap src = source; 146 SkBitmap src = source;
147 SkIPoint srcOffset = SkIPoint::Make(0, 0); 147 SkIPoint srcOffset = SkIPoint::Make(0, 0);
148 if (getInput(0) && !getInput(0)->filterImage(proxy, source, ctx, &src, &srcO ffset)) { 148 if (getInput(0) && !getInput(0)->filterImage(proxy, source, ctx, &src, &srcO ffset)) {
149 return false; 149 return false;
150 } 150 }
151 151
152 if (src.colorType() != kPMColor_SkColorType) { 152 if (src.colorType() != kN32_SkColorType) {
153 return false; 153 return false;
154 } 154 }
155 155
156 SkIRect bounds; 156 SkIRect bounds;
157 if (!this->applyCropRect(ctx, proxy, src, &srcOffset, &bounds, &src)) { 157 if (!this->applyCropRect(ctx, proxy, src, &srcOffset, &bounds, &src)) {
158 return false; 158 return false;
159 } 159 }
160 160
161 SkAutoLockPixels alp(src); 161 SkAutoLockPixels alp(src);
162 if (!src.getPixels()) { 162 if (!src.getPixels()) {
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
581 SkBitmap* result, SkIPoint* offset) con st { 581 SkBitmap* result, SkIPoint* offset) con st {
582 return this->filterImageGPUGeneric(true, proxy, src, ctx, result, offset); 582 return this->filterImageGPUGeneric(true, proxy, src, ctx, result, offset);
583 } 583 }
584 584
585 bool SkErodeImageFilter::filterImageGPU(Proxy* proxy, const SkBitmap& src, const Context& ctx, 585 bool SkErodeImageFilter::filterImageGPU(Proxy* proxy, const SkBitmap& src, const Context& ctx,
586 SkBitmap* result, SkIPoint* offset) cons t { 586 SkBitmap* result, SkIPoint* offset) cons t {
587 return this->filterImageGPUGeneric(false, proxy, src, ctx, result, offset); 587 return this->filterImageGPUGeneric(false, proxy, src, ctx, result, offset);
588 } 588 }
589 589
590 #endif 590 #endif
OLDNEW
« no previous file with comments | « src/effects/SkMatrixConvolutionImageFilter.cpp ('k') | src/effects/SkTransparentShader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698