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

Unified Diff: src/effects/SkGpuBlurUtils.cpp

Issue 1413673002: Remove DrawingMgr shims from GrContext (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove abandon, reset & flush from public DrawingMgr API Created 5 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: src/effects/SkGpuBlurUtils.cpp
diff --git a/src/effects/SkGpuBlurUtils.cpp b/src/effects/SkGpuBlurUtils.cpp
index ec37505d3eb041255ca547dbdda0981a109978ea..c897951925da0e32e88b3c3d7b883af6644ba917 100644
--- a/src/effects/SkGpuBlurUtils.cpp
+++ b/src/effects/SkGpuBlurUtils.cpp
@@ -220,7 +220,7 @@ GrTexture* GaussianBlur(GrContext* context,
i < scaleFactorY ? 0.5f : 1.0f);
SkAutoTUnref<GrDrawContext> dstDrawContext(
- context->drawContext(dstTexture->asRenderTarget()));
+ context->drawingMgr().drawContext(dstTexture->asRenderTarget()));
if (!dstDrawContext) {
return nullptr;
}
@@ -243,7 +243,7 @@ GrTexture* GaussianBlur(GrContext* context,
SkRect dstRect = SkRect::MakeWH(srcRect.width(), srcRect.height());
SkAutoTUnref<GrDrawContext> dstDrawContext(
- context->drawContext(dstTexture->asRenderTarget()));
+ context->drawingMgr().drawContext(dstTexture->asRenderTarget()));
if (!dstDrawContext) {
return nullptr;
}
@@ -260,7 +260,8 @@ GrTexture* GaussianBlur(GrContext* context,
if (scaleFactorX > 1) {
// TODO: if we pass in the source draw context we don't need this here
if (!srcDrawContext) {
- srcDrawContext.reset(context->drawContext(srcTexture->asRenderTarget()));
+ srcDrawContext.reset(
+ context->drawingMgr().drawContext(srcTexture->asRenderTarget()));
if (!srcDrawContext) {
return nullptr;
}
@@ -275,7 +276,7 @@ GrTexture* GaussianBlur(GrContext* context,
SkRect dstRect = SkRect::MakeWH(srcRect.width(), srcRect.height());
SkAutoTUnref<GrDrawContext> dstDrawContext(
- context->drawContext(dstTexture->asRenderTarget()));
+ context->drawingMgr().drawContext(dstTexture->asRenderTarget()));
if (!dstDrawContext) {
return nullptr;
}
@@ -293,7 +294,8 @@ GrTexture* GaussianBlur(GrContext* context,
if (scaleFactorY > 1 || sigmaX > 0.0f) {
// TODO: if we pass in the source draw context we don't need this here
if (!srcDrawContext) {
- srcDrawContext.reset(context->drawContext(srcTexture->asRenderTarget()));
+ srcDrawContext.reset(
+ context->drawingMgr().drawContext(srcTexture->asRenderTarget()));
if (!srcDrawContext) {
return nullptr;
}
@@ -309,7 +311,7 @@ GrTexture* GaussianBlur(GrContext* context,
SkRect dstRect = SkRect::MakeWH(srcRect.width(), srcRect.height());
SkAutoTUnref<GrDrawContext> dstDrawContext(
- context->drawContext(dstTexture->asRenderTarget()));
+ context->drawingMgr().drawContext(dstTexture->asRenderTarget()));
if (!dstDrawContext) {
return nullptr;
}
@@ -347,7 +349,7 @@ GrTexture* GaussianBlur(GrContext* context,
scale_rect(&dstRect, (float) scaleFactorX, (float) scaleFactorY);
SkAutoTUnref<GrDrawContext> dstDrawContext(
- context->drawContext(dstTexture->asRenderTarget()));
+ context->drawingMgr().drawContext(dstTexture->asRenderTarget()));
if (!dstDrawContext) {
return nullptr;
}

Powered by Google App Engine
This is Rietveld 408576698