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 SkPictureData_DEFINED | 8 #ifndef SkPictureData_DEFINED |
9 #define SkPictureData_DEFINED | 9 #define SkPictureData_DEFINED |
10 | 10 |
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
175 */ | 175 */ |
176 bool suitableForGpuRasterization(GrContext* context, const char **reason, | 176 bool suitableForGpuRasterization(GrContext* context, const char **reason, |
177 int sampleCount = 0) const; | 177 int sampleCount = 0) const; |
178 | 178 |
179 /** | 179 /** |
180 * Calls getRecommendedSampleCount with GrPixelConfig and dpi to calculate s
ampleCount | 180 * Calls getRecommendedSampleCount with GrPixelConfig and dpi to calculate s
ampleCount |
181 * and then calls the above version of suitableForGpuRasterization | 181 * and then calls the above version of suitableForGpuRasterization |
182 */ | 182 */ |
183 bool suitableForGpuRasterization(GrContext* context, const char **reason, | 183 bool suitableForGpuRasterization(GrContext* context, const char **reason, |
184 GrPixelConfig config, SkScalar dpi) const; | 184 GrPixelConfig config, SkScalar dpi) const; |
185 | |
186 bool suitableForLayerOptimization() const; | |
187 #endif | 185 #endif |
188 | 186 |
189 private: | 187 private: |
190 friend class SkPicture; // needed in SkPicture::clone (rm when it is removed
) | 188 friend class SkPicture; // needed in SkPicture::clone (rm when it is removed
) |
191 | 189 |
192 void init(); | 190 void init(); |
193 | 191 |
194 // these help us with reading/writing | 192 // these help us with reading/writing |
195 bool parseStreamTag(SkStream*, uint32_t tag, uint32_t size, SkPicture::Insta
llPixelRefProc); | 193 bool parseStreamTag(SkStream*, uint32_t tag, uint32_t size, SkPicture::Insta
llPixelRefProc); |
196 bool parseBufferTag(SkReadBuffer&, uint32_t tag, uint32_t size); | 194 bool parseBufferTag(SkReadBuffer&, uint32_t tag, uint32_t size); |
(...skipping 25 matching lines...) Expand all Loading... |
222 | 220 |
223 const SkPictInfo fInfo; | 221 const SkPictInfo fInfo; |
224 | 222 |
225 static void WriteFactories(SkWStream* stream, const SkFactorySet& rec); | 223 static void WriteFactories(SkWStream* stream, const SkFactorySet& rec); |
226 static void WriteTypefaces(SkWStream* stream, const SkRefCntSet& rec); | 224 static void WriteTypefaces(SkWStream* stream, const SkRefCntSet& rec); |
227 | 225 |
228 void initForPlayback() const; | 226 void initForPlayback() const; |
229 }; | 227 }; |
230 | 228 |
231 #endif | 229 #endif |
OLD | NEW |