diff options
author | Brian Salomon <bsalomon@google.com> | 2017-08-28 15:32:01 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-08-28 20:02:16 +0000 |
commit | 3416969605137214a9e1b1fb85182e5640a655ab (patch) | |
tree | 7b81edfaf359d2e50bab4ef3f2d27c38702da000 /src/gpu/GrRenderTargetContext.h | |
parent | 5b071782585024bd75a203f3cde0429bfb7ec99d (diff) |
Revert "Revert "Revert "Revert "Add GrTextureOp and use to implement SkGpuDevice::drawImage[Rect]() when possible""""
This reverts commit a184ac7e0cdb26919369151f606c194358c94ff5.
Change-Id: I2a4a1b713fd998ba33a5f85a34be1645438a7ac9
Reviewed-on: https://skia-review.googlesource.com/39400
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/GrRenderTargetContext.h')
-rw-r--r-- | src/gpu/GrRenderTargetContext.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/gpu/GrRenderTargetContext.h b/src/gpu/GrRenderTargetContext.h index a73f4c9f8f..084e1530a4 100644 --- a/src/gpu/GrRenderTargetContext.h +++ b/src/gpu/GrRenderTargetContext.h @@ -135,6 +135,17 @@ public: const SkMatrix& localMatrix); /** + * Creates an op that draws a subrectangle of a texture. The passed color is modulated by the + * texture's color. 'srcRect' specifies the rectangle of the texture to draw. 'dstRect' + * specifies the rectangle to draw in local coords which will be transformed by 'viewMatrix' to + * device space. The edges of the rendered rectangle are not antialiased. This asserts that the + * view matrix does not have perspective. + */ + void drawTextureAffine(const GrClip& clip, sk_sp<GrTextureProxy>, GrSamplerParams::FilterMode, + GrColor, const SkRect& srcRect, const SkRect& dstRect, + const SkMatrix& viewMatrix, sk_sp<GrColorSpaceXform>); + + /** * Draw a roundrect using a paint. * * @param paint describes how to color pixels. |