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

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

Issue 234833003: 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 | « src/core/SkBitmap.cpp ('k') | src/core/SkBitmapFilter.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 "SkBitmapDevice.h" 8 #include "SkBitmapDevice.h"
9 #include "SkConfig8888.h" 9 #include "SkConfig8888.h"
10 #include "SkDraw.h" 10 #include "SkDraw.h"
(...skipping 27 matching lines...) Expand all
38 } 38 }
39 39
40 SkAlphaType canonicalAlphaType = info.alphaType(); 40 SkAlphaType canonicalAlphaType = info.alphaType();
41 41
42 switch (info.colorType()) { 42 switch (info.colorType()) {
43 case kAlpha_8_SkColorType: 43 case kAlpha_8_SkColorType:
44 break; 44 break;
45 case kRGB_565_SkColorType: 45 case kRGB_565_SkColorType:
46 canonicalAlphaType = kOpaque_SkAlphaType; 46 canonicalAlphaType = kOpaque_SkAlphaType;
47 break; 47 break;
48 case kN32_SkColorType: 48 case kPMColor_SkColorType:
49 break; 49 break;
50 default: 50 default:
51 return false; 51 return false;
52 } 52 }
53 53
54 if (newAlphaType) { 54 if (newAlphaType) {
55 *newAlphaType = canonicalAlphaType; 55 *newAlphaType = canonicalAlphaType;
56 } 56 }
57 return true; 57 return true;
58 } 58 }
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after
464 paint.getStyle() != SkPaint::kFill_Style || 464 paint.getStyle() != SkPaint::kFill_Style ||
465 !SkXfermode::IsMode(paint.getXfermode(), SkXfermode::kSrcOver_Mode)) { 465 !SkXfermode::IsMode(paint.getXfermode(), SkXfermode::kSrcOver_Mode)) {
466 // turn off lcd 466 // turn off lcd
467 flags->fFlags = paint.getFlags() & ~SkPaint::kLCDRenderText_Flag; 467 flags->fFlags = paint.getFlags() & ~SkPaint::kLCDRenderText_Flag;
468 flags->fHinting = paint.getHinting(); 468 flags->fHinting = paint.getHinting();
469 return true; 469 return true;
470 } 470 }
471 // we're cool with the paint as is 471 // we're cool with the paint as is
472 return false; 472 return false;
473 } 473 }
OLDNEW
« no previous file with comments | « src/core/SkBitmap.cpp ('k') | src/core/SkBitmapFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698