diff options
author | Chris Dalton <csmartdalton@google.com> | 2018-04-10 00:21:19 -0600 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-04-10 15:35:02 +0000 |
commit | 7ca3b7bbe31545a78ff3a7aee8cb58b95eba587b (patch) | |
tree | f4ae527041f73f5d24483d8b1ca2aed63147a899 /samplecode | |
parent | 2e9f0575e8ef19e9bc47db15453f4ec720508e28 (diff) |
ccpr: Remove fCurrAnchorPoint from GrCCGeometry
Removes fCurrAnchorPoint, and various other cleanups. fCurrAnchorPoint
was originally added because points were expected to be written directly
to mapped GPU buffers, which is not going to happen anymore.
Bug: skia:
Change-Id: Icaf8d09dae218f58c19a2f368f3cd281e285e2dd
Reviewed-on: https://skia-review.googlesource.com/119984
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Diffstat (limited to 'samplecode')
-rw-r--r-- | samplecode/SampleCCPRGeometry.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/samplecode/SampleCCPRGeometry.cpp b/samplecode/SampleCCPRGeometry.cpp index 7ddf91f0ae..a6e408749a 100644 --- a/samplecode/SampleCCPRGeometry.cpp +++ b/samplecode/SampleCCPRGeometry.cpp @@ -245,7 +245,7 @@ void CCPRGeometryView::updateGpuData() { fCubicType = GrPathUtils::getCubicKLM(fPoints, &fCubicKLM, t, s); GrCCGeometry geometry; geometry.beginContour(fPoints[0]); - geometry.cubicTo(fPoints[1], fPoints[2], fPoints[3], kDebugBloat / 2, kDebugBloat / 2); + geometry.cubicTo(fPoints, kDebugBloat / 2, kDebugBloat / 2); geometry.endContour(); int ptsIdx = 0; for (GrCCGeometry::Verb verb : geometry.verbs()) { @@ -265,9 +265,10 @@ void CCPRGeometryView::updateGpuData() { } } } else if (PrimitiveType::kQuadratics == fPrimitiveType) { + SkPoint P3[3] = {fPoints[0], fPoints[1], fPoints[3]}; GrCCGeometry geometry; - geometry.beginContour(fPoints[0]); - geometry.quadraticTo(fPoints[1], fPoints[3]); + geometry.beginContour(P3[0]); + geometry.quadraticTo(P3); geometry.endContour(); int ptsIdx = 0; for (GrCCGeometry::Verb verb : geometry.verbs()) { |