OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 "SkBitmap.h" | 8 #include "SkBitmap.h" |
9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
10 #include "SkData.h" | 10 #include "SkData.h" |
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
280 } | 280 } |
281 | 281 |
282 SkImage* SkImage::NewFromPicture(const SkPicture* picture, const SkISize& dimens
ions, | 282 SkImage* SkImage::NewFromPicture(const SkPicture* picture, const SkISize& dimens
ions, |
283 const SkMatrix* matrix, const SkPaint* paint) { | 283 const SkMatrix* matrix, const SkPaint* paint) { |
284 if (!picture) { | 284 if (!picture) { |
285 return nullptr; | 285 return nullptr; |
286 } | 286 } |
287 return NewFromGenerator(SkImageGenerator::NewFromPicture(dimensions, picture
, matrix, paint)); | 287 return NewFromGenerator(SkImageGenerator::NewFromPicture(dimensions, picture
, matrix, paint)); |
288 } | 288 } |
289 | 289 |
| 290 bool SkImage::isLazyGenerated() const { |
| 291 return as_IB(this)->onIsLazyGenerated(); |
| 292 } |
| 293 |
290 ////////////////////////////////////////////////////////////////////////////////
////// | 294 ////////////////////////////////////////////////////////////////////////////////
////// |
291 | 295 |
292 #if !SK_SUPPORT_GPU | 296 #if !SK_SUPPORT_GPU |
293 | 297 |
294 SkImage* SkImage::NewFromTexture(GrContext*, const GrBackendTextureDesc&, SkAlph
aType, | 298 SkImage* SkImage::NewFromTexture(GrContext*, const GrBackendTextureDesc&, SkAlph
aType, |
295 TextureReleaseProc, ReleaseContext) { | 299 TextureReleaseProc, ReleaseContext) { |
296 return NULL; | 300 return NULL; |
297 } | 301 } |
298 | 302 |
299 SkImage* SkImage::NewFromAdoptedTexture(GrContext*, const GrBackendTextureDesc&,
SkAlphaType) { | 303 SkImage* SkImage::NewFromAdoptedTexture(GrContext*, const GrBackendTextureDesc&,
SkAlphaType) { |
300 return NULL; | 304 return NULL; |
301 } | 305 } |
302 | 306 |
303 SkImage* SkImage::NewFromTextureCopy(GrContext*, const GrBackendTextureDesc&, Sk
AlphaType) { | 307 SkImage* SkImage::NewFromTextureCopy(GrContext*, const GrBackendTextureDesc&, Sk
AlphaType) { |
304 return NULL; | 308 return NULL; |
305 } | 309 } |
306 | 310 |
307 #endif | 311 #endif |
OLD | NEW |