| 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 GrRenderTarget_DEFINED | 8 #ifndef GrRenderTarget_DEFINED |
| 9 #define GrRenderTarget_DEFINED | 9 #define GrRenderTarget_DEFINED |
| 10 | 10 |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 SkIRect fResolveRect; | 186 SkIRect fResolveRect; |
| 187 | 187 |
| 188 // The last drawTarget that wrote to or is currently going to write to this
renderTarget | 188 // The last drawTarget that wrote to or is currently going to write to this
renderTarget |
| 189 // The drawTarget can be closed (e.g., no draw context is currently bound | 189 // The drawTarget can be closed (e.g., no draw context is currently bound |
| 190 // to this renderTarget). | 190 // to this renderTarget). |
| 191 // This back-pointer is required so that we can add a dependancy between | 191 // This back-pointer is required so that we can add a dependancy between |
| 192 // the drawTarget used to create the current contents of this renderTarget | 192 // the drawTarget used to create the current contents of this renderTarget |
| 193 // and the drawTarget of a destination renderTarget to which this one is bei
ng drawn. | 193 // and the drawTarget of a destination renderTarget to which this one is bei
ng drawn. |
| 194 GrDrawTarget* fLastDrawTarget; | 194 GrDrawTarget* fLastDrawTarget; |
| 195 | 195 |
| 196 /** |
| 197 * Info struct filled out by GrGpu that contains hardware-specific multisamp
le info. |
| 198 */ |
| 199 struct MultisampleSpecs { |
| 200 MultisampleSpecs() { memset(this, 0, sizeof(*this)); } |
| 201 /** |
| 202 * The actual number of samples allocated for the render target. NOTE: t
his value can be |
| 203 * greater than the surface descriptor's sample count. |
| 204 */ |
| 205 int fEffectiveSampleCnt; |
| 206 /** |
| 207 * If sample locations are supported, contains a unique ID that identifi
es the render |
| 208 * target's sample pattern. Otherwise 0. |
| 209 */ |
| 210 uint16_t fSamplePatternID; |
| 211 /** |
| 212 * If supported, references the render target's sample locations. Otherw
ise nullptr. The |
| 213 * sample locations are stored in device space, with the center of the p
ixel at [0.5, 0.5]. |
| 214 */ |
| 215 const SkPoint* fSampleLocations; |
| 216 }; |
| 217 |
| 218 SkAutoTDelete<MultisampleSpecs> fMultisampleSpecs; |
| 219 |
| 196 typedef GrSurface INHERITED; | 220 typedef GrSurface INHERITED; |
| 197 }; | 221 }; |
| 198 | 222 |
| 199 | 223 |
| 200 #endif | 224 #endif |
| OLD | NEW |