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

Side by Side Diff: src/core/SkPixmap.cpp

Issue 2396953002: Revert[8] "replace SkXfermode obj with SkBlendMode enum in paints" (Closed)
Patch Set: add tmp virtual to unroll legacy arithmodes Created 4 years, 2 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/core/SkPaintPriv.cpp ('k') | src/core/SkRasterPipelineBlitter.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 2015 Google Inc. 2 * Copyright 2015 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 "SkColorPriv.h" 8 #include "SkColorPriv.h"
9 #include "SkConfig8888.h" 9 #include "SkConfig8888.h"
10 #include "SkData.h" 10 #include "SkData.h"
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 } 260 }
261 bitmap.setIsVolatile(true); // so we don't try to cache it 261 bitmap.setIsVolatile(true); // so we don't try to cache it
262 262
263 auto surface(SkSurface::MakeRasterDirect(dst.info(), dst.writable_addr(), ds t.rowBytes())); 263 auto surface(SkSurface::MakeRasterDirect(dst.info(), dst.writable_addr(), ds t.rowBytes()));
264 if (!surface) { 264 if (!surface) {
265 return false; 265 return false;
266 } 266 }
267 267
268 SkPaint paint; 268 SkPaint paint;
269 paint.setFilterQuality(quality); 269 paint.setFilterQuality(quality);
270 paint.setXfermodeMode(SkXfermode::kSrc_Mode); 270 paint.setBlendMode(SkBlendMode::kSrc);
271 surface->getCanvas()->drawBitmapRect(bitmap, SkRect::MakeIWH(dst.width(), ds t.height()), 271 surface->getCanvas()->drawBitmapRect(bitmap, SkRect::MakeIWH(dst.width(), ds t.height()),
272 &paint); 272 &paint);
273 return true; 273 return true;
274 } 274 }
275 275
276 //////////////////////////////////////////////////////////////////////////////// ////////////////// 276 //////////////////////////////////////////////////////////////////////////////// //////////////////
OLDNEW
« no previous file with comments | « src/core/SkPaintPriv.cpp ('k') | src/core/SkRasterPipelineBlitter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698