diff options
author | 2017-06-05 09:26:07 -0400 | |
---|---|---|
committer | 2017-06-05 14:03:10 +0000 | |
commit | eee4d6e4e8cc5c4c79f065abcc3ce609f71238f9 (patch) | |
tree | 9a855a9892a8b3017370164355b88c2a4ac9c89c /src/gpu/effects/GrSimpleTextureEffect.h | |
parent | 9beafc41afa3c78ffa12649dcde73628c277da9c (diff) |
Make instantiate return a Boolean
From an off-line conversation:
The longer term idea will be to create a helper class isolates the
ability to instantiate proxies until flush time. The peek* methods
could then be moved to GrSurfaceProxy.
Change-Id: I8e8c02c098475b77d515791c0d6b81f7e4a327dd
Reviewed-on: https://skia-review.googlesource.com/18076
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/gpu/effects/GrSimpleTextureEffect.h')
-rw-r--r-- | src/gpu/effects/GrSimpleTextureEffect.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/gpu/effects/GrSimpleTextureEffect.h b/src/gpu/effects/GrSimpleTextureEffect.h index 8e0e4b0fb1..0b01ac79a3 100644 --- a/src/gpu/effects/GrSimpleTextureEffect.h +++ b/src/gpu/effects/GrSimpleTextureEffect.h @@ -28,8 +28,7 @@ public: // MDB TODO: remove this instantiation once instantiation is pushed past the // TextureSamplers. Instantiation failure in the TextureSampler is difficult to // recover from. - GrTexture* temp = proxy->instantiateTexture(resourceProvider); - if (!temp) { + if (!proxy->instantiate(resourceProvider)) { return nullptr; } @@ -48,8 +47,7 @@ public: // MDB TODO: remove this instantiation once instantiation is pushed past the // TextureSamplers. Instantiation failure in the TextureSampler is difficult to // recover from. - GrTexture* temp = proxy->instantiateTexture(resourceProvider); - if (!temp) { + if (!proxy->instantiate(resourceProvider)) { return nullptr; } @@ -67,8 +65,7 @@ public: // MDB TODO: remove this instantiation once instantiation is pushed past the // TextureSamplers. Instantiation failure in the TextureSampler is difficult to // recover from. - GrTexture* temp = proxy->instantiateTexture(resourceProvider); - if (!temp) { + if (!proxy->instantiate(resourceProvider)) { return nullptr; } |