Revert of Use the GrCacheable ID to eliminate the need for notifications to GrGpuGL when textures and RTs are⦠(https://codereview.chromium.org/376703009/)
Reason for revert:
Trying to unblock roll wedged on 64 bit intrinsic call on XP
Original issue's description:
> Use the GrCacheable ID to eliminate the need for notifications to GrGpuGL when textures and RTs are deleted.
>
> Also, rename GrCacheable::getGenerationID() to getInstanceID() since it doesn't behave like other "generation" IDs.
>
> Committed: https://skia.googlesource.com/skia/+/91bdbcdbbdf5cdf0fdb4518a0d30206c964cfdf6
R=jvanverth@google.com, bsalomon@google.com
TBR=bsalomon@google.com, jvanverth@google.com
NOTREECHECKS=true
NOTRY=true
Author: robertphillips@google.com
Review URL: https://codereview.chromium.org/405023003
diff --git a/src/gpu/GrBitmapTextContext.cpp b/src/gpu/GrBitmapTextContext.cpp
index 78b6174..25c13ec 100755
--- a/src/gpu/GrBitmapTextContext.cpp
+++ b/src/gpu/GrBitmapTextContext.cpp
@@ -56,7 +56,7 @@
fCurrTexture = NULL;
fCurrVertex = 0;
- fEffectTextureInstanceID = 0;
+ fEffectTextureGenID = 0;
fVertices = NULL;
fMaxVertices = 0;
@@ -94,11 +94,11 @@
SkASSERT(fCurrTexture);
GrTextureParams params(SkShader::kRepeat_TileMode, GrTextureParams::kNone_FilterMode);
- uint64_t textureInstanceID = fCurrTexture->getInstanceID();
+ uint32_t textureGenID = fCurrTexture->getGenerationID();
- if (textureInstanceID != fEffectTextureInstanceID) {
+ if (textureGenID != fEffectTextureGenID) {
fCachedEffect.reset(GrCustomCoordsTextureEffect::Create(fCurrTexture, params));
- fEffectTextureInstanceID = textureInstanceID;
+ fEffectTextureGenID = textureGenID;
}
// This effect could be stored with one of the cache objects (atlas?)