OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 #ifndef SkLayerDrawLooper_DEFINED | 8 #ifndef SkLayerDrawLooper_DEFINED |
9 #define SkLayerDrawLooper_DEFINED | 9 #define SkLayerDrawLooper_DEFINED |
10 | 10 |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 }; | 74 }; |
75 | 75 |
76 virtual SkDrawLooper::Context* createContext(SkCanvas*, void* storage) const
SK_OVERRIDE; | 76 virtual SkDrawLooper::Context* createContext(SkCanvas*, void* storage) const
SK_OVERRIDE; |
77 | 77 |
78 virtual size_t contextSize() const SK_OVERRIDE { return sizeof(LayerDrawLoop
erContext); } | 78 virtual size_t contextSize() const SK_OVERRIDE { return sizeof(LayerDrawLoop
erContext); } |
79 | 79 |
80 virtual bool asABlurShadow(BlurShadowRec* rec) const SK_OVERRIDE; | 80 virtual bool asABlurShadow(BlurShadowRec* rec) const SK_OVERRIDE; |
81 | 81 |
82 SK_TO_STRING_OVERRIDE() | 82 SK_TO_STRING_OVERRIDE() |
83 | 83 |
| 84 #ifdef SK_SUPPORT_LEGACY_DEEPFLATTENING |
| 85 static SkFlattenable* DeepCreateProc(SkReadBuffer& buffer) { |
| 86 return CreateProc(buffer); |
| 87 } |
| 88 virtual Factory getFactory() const SK_OVERRIDE { return DeepCreateProc; } |
| 89 #else |
84 virtual Factory getFactory() const SK_OVERRIDE { return CreateProc; } | 90 virtual Factory getFactory() const SK_OVERRIDE { return CreateProc; } |
| 91 #endif |
85 static SkFlattenable* CreateProc(SkReadBuffer& buffer); | 92 static SkFlattenable* CreateProc(SkReadBuffer& buffer); |
86 | 93 |
87 protected: | 94 protected: |
88 SkLayerDrawLooper(); | 95 SkLayerDrawLooper(); |
89 | 96 |
90 virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; | 97 virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; |
91 | 98 |
92 private: | 99 private: |
93 struct Rec { | 100 struct Rec { |
94 Rec* fNext; | 101 Rec* fNext; |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 SkLayerDrawLooper* detachLooper(); | 160 SkLayerDrawLooper* detachLooper(); |
154 | 161 |
155 private: | 162 private: |
156 Rec* fRecs; | 163 Rec* fRecs; |
157 Rec* fTopRec; | 164 Rec* fTopRec; |
158 int fCount; | 165 int fCount; |
159 }; | 166 }; |
160 }; | 167 }; |
161 | 168 |
162 #endif | 169 #endif |
OLD | NEW |