Index: src/gpu/GrContext.cpp |
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp |
index 819774a076a88b657f270dd7bc171a4a4908aaa6..47095135259eb4e8654fabaaad877baf49125363 100755 |
--- a/src/gpu/GrContext.cpp |
+++ b/src/gpu/GrContext.cpp |
@@ -125,8 +125,8 @@ |
fLayerCache.reset(SkNEW_ARGS(GrLayerCache, (this))); |
- fAARectRenderer = SkNEW(GrAARectRenderer); |
- fOvalRenderer = SkNEW(GrOvalRenderer); |
+ fAARectRenderer = SkNEW_ARGS(GrAARectRenderer, (fGpu)); |
+ fOvalRenderer = SkNEW_ARGS(GrOvalRenderer, (fGpu)); |
fDidTestPMConversions = false; |
@@ -186,6 +186,9 @@ |
delete fDrawBufferIBAllocPool; |
fDrawBufferIBAllocPool = NULL; |
+ fAARectRenderer->reset(); |
+ fOvalRenderer->reset(); |
+ |
fBatchFontCache->freeAll(); |
fLayerCache->freeAll(); |
fTextBlobCache->freeAll(); |
@@ -201,6 +204,9 @@ |
if (fDrawBuffer) { |
fDrawBuffer->purgeResources(); |
} |
+ |
+ fAARectRenderer->reset(); |
+ fOvalRenderer->reset(); |
fBatchFontCache->freeAll(); |
fLayerCache->freeAll(); |
@@ -1834,6 +1840,10 @@ |
return this->prepareToDraw(); |
} |
+const GrIndexBuffer* GrContext::getQuadIndexBuffer() const { |
+ return fGpu->getQuadIndexBuffer(); |
+} |
+ |
namespace { |
void test_pm_conversions(GrContext* ctx, int* pmToUPMValue, int* upmToPMValue) { |
GrConfigConversionEffect::PMConversion pmToUPM; |