aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/batches/GrTessellatingPathRenderer.cpp
diff options
context:
space:
mode:
authorGravatar reed <reed@chromium.org>2015-09-17 20:16:13 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-09-17 20:16:13 -0700
commit1b55a963a2374a14bb82eb887bb99ee91680f0eb (patch)
treea15774af26154d677a16d718ba52d7a401bfa868 /src/gpu/batches/GrTessellatingPathRenderer.cpp
parent48e3a45ade15c52c0c1a10cb00907dd444897745 (diff)
Reland of add a ClassID function to GrBatch (patchset #1 id:1 of https://codereview.chromium.org/1353043002/ )
Reason for revert: DEPS roll seems to have landed w/o this revert, so revert it again Original issue's description: > Revert of add a ClassID function to GrBatch (patchset #5 id:80001 of https://codereview.chromium.org/1352813003/ ) > > Reason for revert: > Speculative revert to unblock DEPS roll > > Original issue's description: > > add a ClassID function to GrBatch > > > > BUG=skia: > > > > Committed: https://skia.googlesource.com/skia/+/4078d529e9e199eea13456db7bf3a63a104ab5b9 > > > > Committed: https://skia.googlesource.com/skia/+/eb44d53cf96a7eaf103a98d76079ce1f5495e343 > > TBR=robertphillips@google.com,bsalomon@google.com,joshualitt@google.com,joshualitt@chromium.org > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/48e3a45ade15c52c0c1a10cb00907dd444897745 TBR=robertphillips@google.com,bsalomon@google.com,joshualitt@google.com,joshualitt@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1344373005
Diffstat (limited to 'src/gpu/batches/GrTessellatingPathRenderer.cpp')
-rw-r--r--src/gpu/batches/GrTessellatingPathRenderer.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/gpu/batches/GrTessellatingPathRenderer.cpp b/src/gpu/batches/GrTessellatingPathRenderer.cpp
index 46fa280cfd..901d38369c 100644
--- a/src/gpu/batches/GrTessellatingPathRenderer.cpp
+++ b/src/gpu/batches/GrTessellatingPathRenderer.cpp
@@ -1385,6 +1385,7 @@ bool GrTessellatingPathRenderer::onCanDrawPath(const CanDrawPathArgs& args) cons
class TessellatingPathBatch : public GrVertexBatch {
public:
+ DEFINE_BATCH_CLASS_ID
static GrDrawBatch* Create(const GrColor& color,
const SkPath& path,
@@ -1587,13 +1588,12 @@ private:
const GrStrokeInfo& stroke,
const SkMatrix& viewMatrix,
const SkRect& clipBounds)
- : fColor(color)
+ : INHERITED(ClassID())
+ , fColor(color)
, fPath(path)
, fStroke(stroke)
, fViewMatrix(viewMatrix)
, fClipBounds(clipBounds) {
- this->initClassID<TessellatingPathBatch>();
-
fBounds = path.getBounds();
if (!stroke.isFillStyle()) {
SkScalar radius = SkScalarHalf(stroke.getWidth());
@@ -1614,6 +1614,8 @@ private:
SkMatrix fViewMatrix;
SkRect fClipBounds; // in source space
GrPipelineOptimizations fPipelineInfo;
+
+ typedef GrVertexBatch INHERITED;
};
bool GrTessellatingPathRenderer::onDrawPath(const DrawPathArgs& args) {