OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 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 | 9 |
10 #include "SkColorPriv.h" | 10 #include "SkColorPriv.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 idx = 10 - (SkColorGetG(dst)+22)/45; | 46 idx = 10 - (SkColorGetG(dst)+22)/45; |
47 } | 47 } |
48 ++idx; | 48 ++idx; |
49 SkASSERT(idx < (int)SK_ARRAY_COUNT(gTable)); | 49 SkASSERT(idx < (int)SK_ARRAY_COUNT(gTable)); |
50 | 50 |
51 return gTable[idx]; | 51 return gTable[idx]; |
52 } | 52 } |
53 | 53 |
54 Factory getFactory() const override { return NULL; } | 54 Factory getFactory() const override { return NULL; } |
55 #ifndef SK_IGNORE_TO_STRING | 55 #ifndef SK_IGNORE_TO_STRING |
56 virtual void toString(SkString* str) const override { str->set("OverdrawXfer
mode"); } | 56 void toString(SkString* str) const override { str->set("OverdrawXfermode");
} |
57 #endif | 57 #endif |
58 }; | 58 }; |
59 | 59 |
60 class DebugPaintFilterCanvas : public SkPaintFilterCanvas { | 60 class DebugPaintFilterCanvas : public SkPaintFilterCanvas { |
61 public: | 61 public: |
62 DebugPaintFilterCanvas(int width, int height, bool overdrawViz, bool overrid
eFilterQuality, | 62 DebugPaintFilterCanvas(int width, int height, bool overdrawViz, bool overrid
eFilterQuality, |
63 SkFilterQuality quality) | 63 SkFilterQuality quality) |
64 : INHERITED(width, height) | 64 : INHERITED(width, height) |
65 , fOverdrawXfermode(overdrawViz ? SkNEW(OverdrawXfermode) : NULL) | 65 , fOverdrawXfermode(overdrawViz ? SkNEW(OverdrawXfermode) : NULL) |
66 , fOverrideFilterQuality(overrideFilterQuality) | 66 , fOverrideFilterQuality(overrideFilterQuality) |
(...skipping 606 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
673 } | 673 } |
674 | 674 |
675 bool SkDebugCanvas::lastClipStackData(const SkPath& devPath) { | 675 bool SkDebugCanvas::lastClipStackData(const SkPath& devPath) { |
676 if (fCalledAddStackData) { | 676 if (fCalledAddStackData) { |
677 fClipStackData.appendf("<br>"); | 677 fClipStackData.appendf("<br>"); |
678 addPathData(devPath, "pathOut"); | 678 addPathData(devPath, "pathOut"); |
679 return true; | 679 return true; |
680 } | 680 } |
681 return false; | 681 return false; |
682 } | 682 } |
OLD | NEW |