| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2010 Google Inc. | 3 * Copyright 2010 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #ifndef GrDrawTarget_DEFINED | 10 #ifndef GrDrawTarget_DEFINED |
| (...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 425 /** | 425 /** |
| 426 * Function that determines whether a copySurface call would succeed without | 426 * Function that determines whether a copySurface call would succeed without |
| 427 * performing the copy. | 427 * performing the copy. |
| 428 */ | 428 */ |
| 429 bool canCopySurface(GrSurface* dst, | 429 bool canCopySurface(GrSurface* dst, |
| 430 GrSurface* src, | 430 GrSurface* src, |
| 431 const SkIRect& srcRect, | 431 const SkIRect& srcRect, |
| 432 const SkIPoint& dstPoint); | 432 const SkIPoint& dstPoint); |
| 433 | 433 |
| 434 /** | 434 /** |
| 435 * This is can be called before allocating a texture to be a dst for copySur
face. It will |
| 436 * populate the origin, config, and flags fields of the desc such that copyS
urface is more |
| 437 * likely to succeed and be efficient. |
| 438 */ |
| 439 virtual void initCopySurfaceDstDesc(const GrSurface* src, GrTextureDesc* des
c); |
| 440 |
| 441 |
| 442 /** |
| 435 * Release any resources that are cached but not currently in use. This | 443 * Release any resources that are cached but not currently in use. This |
| 436 * is intended to give an application some recourse when resources are low. | 444 * is intended to give an application some recourse when resources are low. |
| 437 */ | 445 */ |
| 438 virtual void purgeResources() {}; | 446 virtual void purgeResources() {}; |
| 439 | 447 |
| 440 /** | 448 /** |
| 441 * For subclass internal use to invoke a call to onDraw(). See DrawInfo belo
w. | 449 * For subclass internal use to invoke a call to onDraw(). See DrawInfo belo
w. |
| 442 */ | 450 */ |
| 443 void executeDraw(const DrawInfo& info) { this->onDraw(info); } | 451 void executeDraw(const DrawInfo& info) { this->onDraw(info); } |
| 444 | 452 |
| (...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 820 const GrClipData* fClip; | 828 const GrClipData* fClip; |
| 821 GrDrawState* fDrawState; | 829 GrDrawState* fDrawState; |
| 822 GrDrawState fDefaultDraw
State; | 830 GrDrawState fDefaultDraw
State; |
| 823 // The context owns us, not vice-versa, so this ptr is not ref'ed by DrawTar
get. | 831 // The context owns us, not vice-versa, so this ptr is not ref'ed by DrawTar
get. |
| 824 GrContext* fContext; | 832 GrContext* fContext; |
| 825 | 833 |
| 826 typedef GrRefCnt INHERITED; | 834 typedef GrRefCnt INHERITED; |
| 827 }; | 835 }; |
| 828 | 836 |
| 829 #endif | 837 #endif |
| OLD | NEW |