OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 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 SkSpecialImage_DEFINED | 8 #ifndef SkSpecialImage_DEFINED |
9 #define SkSpecialImage_DEFINED | 9 #define SkSpecialImage_DEFINED |
10 | 10 |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
79 uint32_t uniqueID, | 79 uint32_t uniqueID, |
80 sk_sp<GrTexture>, | 80 sk_sp<GrTexture>, |
81 sk_sp<SkColorSpace>, | 81 sk_sp<SkColorSpace>, |
82 const SkSurfaceProps* = nullptr, | 82 const SkSurfaceProps* = nullptr, |
83 SkAlphaType at = kPremul_SkAlphaTyp e); | 83 SkAlphaType at = kPremul_SkAlphaTyp e); |
84 #endif | 84 #endif |
85 | 85 |
86 /** | 86 /** |
87 * Create a new special surface with a backend that is compatible with this special image. | 87 * Create a new special surface with a backend that is compatible with this special image. |
88 */ | 88 */ |
89 sk_sp<SkSpecialSurface> makeSurface(const SkImageInfo&) const; | 89 sk_sp<SkSpecialSurface> makeSurface(const SkIRect& size, |
bsalomon
2016/09/21 13:30:55
SkISize?
| |
90 SkAlphaType at = kPremul_SkAlphaType) co nst; | |
90 | 91 |
91 /** | 92 /** |
92 * Create a new surface with a backend that is compatible with this special image. | 93 * Create a new surface with a backend that is compatible with this special image. |
93 * TODO: switch this to makeSurface once we resolved the naming issue | 94 * TODO: switch this to makeSurface once we resolved the naming issue |
94 */ | 95 */ |
95 sk_sp<SkSurface> makeTightSurface(const SkImageInfo&) const; | 96 sk_sp<SkSurface> makeTightSurface(const SkImageInfo&) const; |
96 | 97 |
97 /** | 98 /** |
98 * Extract a subset of this special image and return it as a special image. | 99 * Extract a subset of this special image and return it as a special image. |
99 * It may or may not point to the same backing memory. | 100 * It may or may not point to the same backing memory. |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
140 | 141 |
141 private: | 142 private: |
142 const SkSurfaceProps fProps; | 143 const SkSurfaceProps fProps; |
143 const SkIRect fSubset; | 144 const SkIRect fSubset; |
144 const uint32_t fUniqueID; | 145 const uint32_t fUniqueID; |
145 | 146 |
146 typedef SkRefCnt INHERITED; | 147 typedef SkRefCnt INHERITED; |
147 }; | 148 }; |
148 | 149 |
149 #endif | 150 #endif |
OLD | NEW |