Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(701)

Side by Side Diff: src/gpu/GrContext.cpp

Issue 1264283002: Add abliity to set textblob cache budget to GrContext (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "GrContext.h" 9 #include "GrContext.h"
10 10
(...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after
744 } 744 }
745 if (maxTextureBytes) { 745 if (maxTextureBytes) {
746 *maxTextureBytes = fResourceCache->getMaxResourceBytes(); 746 *maxTextureBytes = fResourceCache->getMaxResourceBytes();
747 } 747 }
748 } 748 }
749 749
750 void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) { 750 void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) {
751 fResourceCache->setLimits(maxTextures, maxTextureBytes); 751 fResourceCache->setLimits(maxTextures, maxTextureBytes);
752 } 752 }
753 753
754 void GrContext::setTextBlobCacheLimit(size_t bytes) {
755 fTextBlobCache->setBudget(bytes);
756 }
757
754 ////////////////////////////////////////////////////////////////////////////// 758 //////////////////////////////////////////////////////////////////////////////
755 759
756 void GrContext::addGpuTraceMarker(const GrGpuTraceMarker* marker) { 760 void GrContext::addGpuTraceMarker(const GrGpuTraceMarker* marker) {
757 fGpu->addGpuTraceMarker(marker); 761 fGpu->addGpuTraceMarker(marker);
758 } 762 }
759 763
760 void GrContext::removeGpuTraceMarker(const GrGpuTraceMarker* marker) { 764 void GrContext::removeGpuTraceMarker(const GrGpuTraceMarker* marker) {
761 fGpu->removeGpuTraceMarker(marker); 765 fGpu->removeGpuTraceMarker(marker);
762 } 766 }
763 767
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698