aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrDrawOpAtlas.cpp
diff options
context:
space:
mode:
authorGravatar Robert Phillips <robertphillips@google.com>2018-01-19 12:56:09 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-01-19 18:36:35 +0000
commit88260b549fcff1715ab9bb9b1a442e0abacce2e5 (patch)
treeacfebce4d3e03928c72f30e517c6d0a593d43661 /src/gpu/GrDrawOpAtlas.cpp
parent9cec1bc1a707b43e1c338c642b10f4ba9400d518 (diff)
Split GrContext into Normal/DDL flavors
Change-Id: If37d8a236bd71e2d7121eaafb9d7c7b08328b10f Reviewed-on: https://skia-review.googlesource.com/84863 Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/GrDrawOpAtlas.cpp')
-rw-r--r--src/gpu/GrDrawOpAtlas.cpp15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/gpu/GrDrawOpAtlas.cpp b/src/gpu/GrDrawOpAtlas.cpp
index 1d41060eb7..e564e63b04 100644
--- a/src/gpu/GrDrawOpAtlas.cpp
+++ b/src/gpu/GrDrawOpAtlas.cpp
@@ -464,18 +464,9 @@ bool GrDrawOpAtlas::createNewPage() {
desc.fHeight = fTextureHeight;
desc.fConfig = fPixelConfig;
- // We don't want to flush the context so we claim we're in the middle of flushing so as to
- // guarantee we do not recieve a texture with pending IO
- // TODO: Determine how to avoid having to do this. (https://bug.skia.org/4156)
- static const uint32_t kFlags = GrResourceProvider::kNoPendingIO_Flag;
- // MDB TODO: for now, wrap an instantiated texture. Having the deferred instantiation
- // possess the correct properties (e.g., no pendingIO) should fall out of the system but
- // should receive special attention.
- // Note: When switching over to the deferred proxy, use the kExact flag to create
- // the atlas and assert that the width & height are powers of 2.
- // DDL TODO: remove this use of createInstantitateProxy & convert it to a testing-only method.
- fProxies[fNumPages] = proxyProvider->createInstantiatedProxy(desc, SkBackingFit::kApprox,
- SkBudgeted::kYes, kFlags);
+ SkASSERT(SkIsPow2(fTextureWidth) && SkIsPow2(fTextureHeight));
+ fProxies[fNumPages] = proxyProvider->createProxy(desc, SkBackingFit::kExact, SkBudgeted::kYes,
+ GrResourceProvider::kNoPendingIO_Flag);
if (!fProxies[fNumPages]) {
return false;
}