aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrDrawTarget.h
diff options
context:
space:
mode:
authorGravatar robertphillips <robertphillips@google.com>2016-07-13 07:48:43 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-07-13 07:48:43 -0700
commit9199a9fef9896636f673372d2ac1c00af036bf85 (patch)
treebe8246e54504ccc2151661fe113956d64a28efda /src/gpu/GrDrawTarget.h
parente3aea10428d1597838fd563c92340beaf969a9b4 (diff)
Move GrDrawTarget::clear logic into GrDrawContext
I found it a bit worrisome that GrDrawTarget was calling back into GrDrawContext. This also moves GrDrawTarget closer to being a simple-ish container of batches. GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2145643003 Review-Url: https://codereview.chromium.org/2145643003
Diffstat (limited to 'src/gpu/GrDrawTarget.h')
-rw-r--r--src/gpu/GrDrawTarget.h12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/gpu/GrDrawTarget.h b/src/gpu/GrDrawTarget.h
index 7b268c2827..5f91baa33b 100644
--- a/src/gpu/GrDrawTarget.h
+++ b/src/gpu/GrDrawTarget.h
@@ -106,6 +106,8 @@ public:
void drawBatch(const GrPipelineBuilder&, GrDrawContext*, const GrClip&, GrDrawBatch*);
+ void addBatch(sk_sp<GrBatch>);
+
/**
* Draws path into the stencil buffer. The fill must be either even/odd or
* winding (not inverse or hairline). It will respect the HW antialias flag
@@ -116,16 +118,6 @@ public:
const GrClip&, const SkMatrix& viewMatrix,
const GrPath*, GrPathRendering::FillType);
- /**
- * Clear the passed in drawContext. Ignores the GrPipelineBuilder and clip. Clears the whole
- * thing if rect is nullptr, otherwise just the rect. If canIgnoreRect is set then the entire
- * drawContext can be optionally cleared.
- */
- void clear(const SkIRect* rect,
- GrColor color,
- bool canIgnoreRect,
- GrDrawContext*);
-
/** Discards the contents render target. */
void discard(GrRenderTarget*);