diff options
author | bsalomon <bsalomon@google.com> | 2014-09-30 06:02:23 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-30 06:02:23 -0700 |
commit | 3d398c876440deaab39bbf2a9b881c337e6dc8d4 (patch) | |
tree | b38c23d2b6742c9d515dd2b19a1cf8fca49a16f0 /src/gpu/SkGr.cpp | |
parent | c0eb9b9818462471f5fc1c47fa549c6052d8bbae (diff) |
GrResourceCache2 manages scratch texture.
BUG=skia:
R=robertphillips@google.com
Author: bsalomon@google.com
Review URL: https://codereview.chromium.org/608883003
Diffstat (limited to 'src/gpu/SkGr.cpp')
-rw-r--r-- | src/gpu/SkGr.cpp | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp index e81abdbae4..d9435459f1 100644 --- a/src/gpu/SkGr.cpp +++ b/src/gpu/SkGr.cpp @@ -369,9 +369,9 @@ bool GrIsBitmapInCache(const GrContext* ctx, return ctx->isTextureInCache(desc, cacheID, params); } -GrTexture* GrLockAndRefCachedBitmapTexture(GrContext* ctx, - const SkBitmap& bitmap, - const GrTextureParams* params) { +GrTexture* GrRefCachedBitmapTexture(GrContext* ctx, + const SkBitmap& bitmap, + const GrTextureParams* params) { GrTexture* result = NULL; bool cache = !bitmap.isVolatile(); @@ -397,13 +397,6 @@ GrTexture* GrLockAndRefCachedBitmapTexture(GrContext* ctx, return result; } -void GrUnlockAndUnrefCachedBitmapTexture(GrTexture* texture) { - SkASSERT(texture->getContext()); - - texture->getContext()->unlockScratchTexture(texture); - texture->unref(); -} - /////////////////////////////////////////////////////////////////////////////// // alphatype is ignore for now, but if GrPixelConfig is expanded to encompass |