aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkImageFilter.cpp
diff options
context:
space:
mode:
authorGravatar joshualitt <joshualitt@google.com>2015-02-25 13:04:43 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-02-25 13:04:44 -0800
commit2907059d0eb1972a300ea1bf0cd4e4febabb9784 (patch)
treef3f565626302891f0b74b870972ae2a4db89df4c /src/core/SkImageFilter.cpp
parentedeccc58606e0421a1ae275e391ee4347c6f52f6 (diff)
Revert of Pass clip to context (patchset #8 id:180001 of https://codereview.chromium.org/936943002/)
Reason for revert: Strange blur problems on nexus 5 Original issue's description: > I'd really like to land this before the branch so speedy reviews are appreciated. > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/586d5d640b19860dfbbd903a5188da1bbbe87336 TBR=jvanverth@google.com,senorblanco@google.com,bsalomon@google.com,senorblanco@chromium.org,joshualitt@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/956083002
Diffstat (limited to 'src/core/SkImageFilter.cpp')
-rw-r--r--src/core/SkImageFilter.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/core/SkImageFilter.cpp b/src/core/SkImageFilter.cpp
index 94b90d6a05..99a1d13548 100644
--- a/src/core/SkImageFilter.cpp
+++ b/src/core/SkImageFilter.cpp
@@ -257,9 +257,7 @@ bool SkImageFilter::filterImageGPU(Proxy* proxy, const SkBitmap& src, const Cont
return false;
}
- // setup new clip
- GrClip clip(dstRect);
-
+ GrContext::AutoClip acs(context, dstRect);
GrFragmentProcessor* fp;
offset->fX = bounds.left();
offset->fY = bounds.top();
@@ -270,8 +268,7 @@ bool SkImageFilter::filterImageGPU(Proxy* proxy, const SkBitmap& src, const Cont
SkASSERT(fp);
GrPaint paint;
paint.addColorProcessor(fp)->unref();
- context->drawNonAARectToRect(dst->asRenderTarget(), clip, paint, SkMatrix::I(), dstRect,
- srcRect);
+ context->drawNonAARectToRect(dst->asRenderTarget(), paint, SkMatrix::I(), dstRect, srcRect);
WrapTexture(dst, bounds.width(), bounds.height(), result);
return true;
@@ -385,7 +382,7 @@ bool SkImageFilter::getInputResultGPU(SkImageFilter::Proxy* proxy,
// matrix with no clip and that the matrix, clip, and render target set before this function was
// called are restored before we return to the caller.
GrContext* context = src.getTexture()->getContext();
-
+ GrContext::AutoWideOpenIdentityDraw awoid(context);
if (this->canFilterImageGPU()) {
return this->filterImageGPU(proxy, src, ctx, result, offset);
} else {