diff options
author | Robert Phillips <robertphillips@google.com> | 2018-03-07 15:13:18 -0500 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-03-08 14:29:11 +0000 |
commit | 5a66efbbab2926793a7f4dc57931253ab3046375 (patch) | |
tree | 5df12b8abca8e8db6fd4a37b38811abef37c117e /tools/gpu | |
parent | fa303398d503a48d054e26dd1582282d3121b8ec (diff) |
Remove GrRestrictedAtlasManager
Philosophically this relies on: https://skia-review.googlesource.com/c/skia/+/111807 (Revise Text & Small Path Atlas so instantiation failure is handled at flush time)
Change-Id: I4fdcf1af8c5e9ffefdfb973104045f4f5d223a4e
Reviewed-on: https://skia-review.googlesource.com/112702
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'tools/gpu')
-rw-r--r-- | tools/gpu/GrTest.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tools/gpu/GrTest.cpp b/tools/gpu/GrTest.cpp index aa2b07e232..2160c7f47e 100644 --- a/tools/gpu/GrTest.cpp +++ b/tools/gpu/GrTest.cpp @@ -93,7 +93,7 @@ void GrContextPriv::setTextBlobCacheLimit_ForTesting(size_t bytes) { } void GrContextPriv::setTextContextAtlasSizes_ForTesting(const GrDrawOpAtlasConfig* configs) { - GrAtlasManager* atlasManager = this->getFullAtlasManager(); + GrAtlasManager* atlasManager = this->getAtlasManager(); if (atlasManager) { atlasManager->setAtlasSizes_ForTesting(configs); } @@ -150,10 +150,13 @@ void GrContextPriv::printGpuStats() const { } sk_sp<SkImage> GrContextPriv::getFontAtlasImage_ForTesting(GrMaskFormat format, unsigned int index) { - auto restrictedAtlasManager = this->getRestrictedAtlasManager(); + auto atlasManager = this->getAtlasManager(); + if (!atlasManager) { + return nullptr; + } unsigned int numProxies; - const sk_sp<GrTextureProxy>* proxies = restrictedAtlasManager->getProxies(format, &numProxies); + const sk_sp<GrTextureProxy>* proxies = atlasManager->getProxies(format, &numProxies); if (index >= numProxies || !proxies[index]) { return nullptr; } |