aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrRenderTargetContext.cpp
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2018-05-21 12:54:39 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-05-21 18:21:08 +0000
commitbe3c1d22c7d3e18cee9f1697827392e16b436df2 (patch)
tree072c9c2e3a29a383b63d083f2483625a32b36401 /src/gpu/GrRenderTargetContext.cpp
parent477094250cd55a38d4d796ab6c50eb57bdba65e1 (diff)
Add perspective support to GrTextureOp.
Bug: skia: Change-Id: Idea4ffae37dc2c2f339af60a2b74ded476091758 Reviewed-on: https://skia-review.googlesource.com/127600 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/gpu/GrRenderTargetContext.cpp')
-rw-r--r--src/gpu/GrRenderTargetContext.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/gpu/GrRenderTargetContext.cpp b/src/gpu/GrRenderTargetContext.cpp
index ded50490f4..86d1dde356 100644
--- a/src/gpu/GrRenderTargetContext.cpp
+++ b/src/gpu/GrRenderTargetContext.cpp
@@ -763,16 +763,15 @@ static bool must_filter(const SkRect& src, const SkRect& dst, const SkMatrix& ct
return !SkScalarIsInt(x) || !SkScalarIsInt(y);
}
-void GrRenderTargetContext::drawTextureAffine(const GrClip& clip, sk_sp<GrTextureProxy> proxy,
- GrSamplerState::Filter filter, GrColor color,
- const SkRect& srcRect, const SkRect& dstRect, GrAA aa,
- const SkMatrix& viewMatrix,
- sk_sp<GrColorSpaceXform> colorSpaceXform) {
+void GrRenderTargetContext::drawTexture(const GrClip& clip, sk_sp<GrTextureProxy> proxy,
+ GrSamplerState::Filter filter, GrColor color,
+ const SkRect& srcRect, const SkRect& dstRect, GrAA aa,
+ const SkMatrix& viewMatrix,
+ sk_sp<GrColorSpaceXform> colorSpaceXform) {
ASSERT_SINGLE_OWNER
RETURN_IF_ABANDONED
SkDEBUGCODE(this->validate();)
- GR_CREATE_TRACE_MARKER_CONTEXT("GrRenderTargetContext", "drawTextureAffine", fContext);
- SkASSERT(!viewMatrix.hasPerspective());
+ GR_CREATE_TRACE_MARKER_CONTEXT("GrRenderTargetContext", "drawTexture", fContext);
if (filter != GrSamplerState::Filter::kNearest && !must_filter(srcRect, dstRect, viewMatrix)) {
filter = GrSamplerState::Filter::kNearest;
}