| Index: src/gpu/GrSurface.cpp
|
| diff --git a/src/gpu/GrSurface.cpp b/src/gpu/GrSurface.cpp
|
| index 52ab4fd11dc2963fa3612b482d84ea8f33eafea7..d15cbdf6e26ccc7fd3b3745cb9ced18747132395 100644
|
| --- a/src/gpu/GrSurface.cpp
|
| +++ b/src/gpu/GrSurface.cpp
|
| @@ -44,3 +44,39 @@ bool GrSurface::savePixels(const char* filename) {
|
|
|
| return true;
|
| }
|
| +
|
| +bool GrSurface::hasPendingRead() const {
|
| + const GrTexture* thisTex = this->asTexture();
|
| + if (thisTex && thisTex->internalHasPendingRead()) {
|
| + return true;
|
| + }
|
| + const GrRenderTarget* thisRT = this->asRenderTarget();
|
| + if (thisRT && thisRT->internalHasPendingRead()) {
|
| + return true;
|
| + }
|
| + return false;
|
| +}
|
| +
|
| +bool GrSurface::hasPendingWrite() const {
|
| + const GrTexture* thisTex = this->asTexture();
|
| + if (thisTex && thisTex->internalHasPendingWrite()) {
|
| + return true;
|
| + }
|
| + const GrRenderTarget* thisRT = this->asRenderTarget();
|
| + if (thisRT && thisRT->internalHasPendingWrite()) {
|
| + return true;
|
| + }
|
| + return false;
|
| +}
|
| +
|
| +bool GrSurface::hasPendingIO() const {
|
| + const GrTexture* thisTex = this->asTexture();
|
| + if (thisTex && thisTex->internalHasPendingIO()) {
|
| + return true;
|
| + }
|
| + const GrRenderTarget* thisRT = this->asRenderTarget();
|
| + if (thisRT && thisRT->internalHasPendingIO()) {
|
| + return true;
|
| + }
|
| + return false;
|
| +}
|
|
|