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 GrGpu_DEFINED | 8 #ifndef GrGpu_DEFINED |
9 #define GrGpu_DEFINED | 9 #define GrGpu_DEFINED |
10 | 10 |
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
238 * be discarded. | 238 * be discarded. |
239 **/ | 239 **/ |
240 virtual void discard(GrRenderTarget* = NULL) = 0; | 240 virtual void discard(GrRenderTarget* = NULL) = 0; |
241 | 241 |
242 /** | 242 /** |
243 * This is can be called before allocating a texture to be a dst for copySur
face. It will | 243 * This is can be called before allocating a texture to be a dst for copySur
face. It will |
244 * populate the origin, config, and flags fields of the desc such that copyS
urface can | 244 * populate the origin, config, and flags fields of the desc such that copyS
urface can |
245 * efficiently succeed. It should only succeed if it can allow copySurface t
o perform a copy | 245 * efficiently succeed. It should only succeed if it can allow copySurface t
o perform a copy |
246 * that would be more effecient than drawing the src to a dst render target. | 246 * that would be more effecient than drawing the src to a dst render target. |
247 */ | 247 */ |
248 virtual bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* des
c) = 0; | 248 virtual bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* des
c) const = 0; |
249 | 249 |
250 // After the client interacts directly with the 3D context state the GrGpu | 250 // After the client interacts directly with the 3D context state the GrGpu |
251 // must resync its internal state and assumptions about 3D context state. | 251 // must resync its internal state and assumptions about 3D context state. |
252 // Each time this occurs the GrGpu bumps a timestamp. | 252 // Each time this occurs the GrGpu bumps a timestamp. |
253 // state of the 3D context | 253 // state of the 3D context |
254 // At 10 resets / frame and 60fps a 64bit timestamp will overflow in about | 254 // At 10 resets / frame and 60fps a 64bit timestamp will overflow in about |
255 // a billion years. | 255 // a billion years. |
256 typedef uint64_t ResetTimestamp; | 256 typedef uint64_t ResetTimestamp; |
257 | 257 |
258 // This timestamp is always older than the current timestamp | 258 // This timestamp is always older than the current timestamp |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
473 GrTraceMarkerSet fActiveT
raceMarkers; | 473 GrTraceMarkerSet fActiveT
raceMarkers; |
474 GrTraceMarkerSet fStoredT
raceMarkers; | 474 GrTraceMarkerSet fStoredT
raceMarkers; |
475 // The context owns us, not vice-versa, so this ptr is not ref'ed by Gpu. | 475 // The context owns us, not vice-versa, so this ptr is not ref'ed by Gpu. |
476 GrContext* fContext
; | 476 GrContext* fContext
; |
477 | 477 |
478 friend class GrPathRendering; | 478 friend class GrPathRendering; |
479 typedef SkRefCnt INHERITED; | 479 typedef SkRefCnt INHERITED; |
480 }; | 480 }; |
481 | 481 |
482 #endif | 482 #endif |
OLD | NEW |