add getter/setter for TextureCache, so that clients can make their budget
decisions at runtime or per-context, rather than just at compile-time. Leaving
in the default values as is.



git-svn-id: http://skia.googlecode.com/svn/trunk@709 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/gpu/src/GrContext.cpp b/gpu/src/GrContext.cpp
index 5128602..ee78848 100644
--- a/gpu/src/GrContext.cpp
+++ b/gpu/src/GrContext.cpp
@@ -232,6 +232,17 @@
     return fGpu->createTexture(desc, srcData, rowBytes);

 }

 

+void GrContext::getTextureCacheLimits(int* maxTextures,

+                                      size_t* maxTextureBytes) const {

+    fTextureCache->getLimits(maxTextures, maxTextureBytes);

+}

+

+void GrContext::setTextureCacheLimits(int maxTextures, size_t maxTextureBytes) {

+    fTextureCache->setLimits(maxTextures, maxTextureBytes);

+}

+

+///////////////////////////////////////////////////////////////////////////////

+

 GrRenderTarget* GrContext::createPlatformRenderTarget(intptr_t platformRenderTarget,

                                                       int width, int height) {

     return fGpu->createPlatformRenderTarget(platformRenderTarget,