| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 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 SkImageCacherator_DEFINED | 8 #ifndef SkImageCacherator_DEFINED |
| 9 #define SkImageCacherator_DEFINED | 9 #define SkImageCacherator_DEFINED |
| 10 | 10 |
| 11 #include "SkImage.h" |
| 11 #include "SkImageGenerator.h" | 12 #include "SkImageGenerator.h" |
| 12 #include "SkMutex.h" | 13 #include "SkMutex.h" |
| 13 #include "SkTemplates.h" | 14 #include "SkTemplates.h" |
| 14 | 15 |
| 15 class GrContext; | 16 class GrContext; |
| 16 class GrTextureParams; | 17 class GrTextureParams; |
| 17 class GrUniqueKey; | 18 class GrUniqueKey; |
| 18 class SkBitmap; | 19 class SkBitmap; |
| 19 class SkImage; | 20 class SkImage; |
| 20 | 21 |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 SkMutex fMutexForGenerator; | 95 SkMutex fMutexForGenerator; |
| 95 SkAutoTDelete<SkImageGenerator> fNotThreadSafeGenerator; | 96 SkAutoTDelete<SkImageGenerator> fNotThreadSafeGenerator; |
| 96 | 97 |
| 97 const SkImageInfo fInfo; | 98 const SkImageInfo fInfo; |
| 98 const SkIPoint fOrigin; | 99 const SkIPoint fOrigin; |
| 99 const uint32_t fUniqueID; | 100 const uint32_t fUniqueID; |
| 100 | 101 |
| 101 friend class GrImageTextureMaker; | 102 friend class GrImageTextureMaker; |
| 102 }; | 103 }; |
| 103 | 104 |
| 105 // Exposed so it can be tested, not meant for external usage per-se |
| 106 // |
| 107 class SkGpuFormatWhitelist : public SkImageGenerator::RefEncodedWhitelist { |
| 108 GrContext* fCtx; |
| 109 public: |
| 110 SkGpuFormatWhitelist(GrContext* ctx) : fCtx(ctx) {} |
| 111 |
| 112 bool includes(SkEncodedFormat format) override; |
| 113 }; |
| 114 |
| 104 #endif | 115 #endif |
| OLD | NEW |