diff options
author | Chris Dalton <csmartdalton@google.com> | 2018-03-21 12:14:10 -0600 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-03-21 18:53:59 +0000 |
commit | 52076d1df56fc2eef7c78fe4f2a9930aba59e803 (patch) | |
tree | 6385192af1a8bef3611922cb1a737b0e1871bb4b /samplecode | |
parent | ca37f32c7014a30352f719d84a57cecfd3a93561 (diff) |
ccpr: Use a more stable formula to find quadratic coordinates
The 3x3 inverse grew unstable on small curves with large coordinates,
not to mention being inefficient. This fixes many bad pixels on the
chalkboard.
Also begins scaling curve gradients by the AA bloat, in order to match
triangle edges more closely and visualize curve AA in the ccpr sample.
Bug: skia:
Change-Id: I0f7da2e7599d4d5c458b3dd307185679dc78bb50
Reviewed-on: https://skia-review.googlesource.com/115527
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'samplecode')
-rw-r--r-- | samplecode/SampleCCPRGeometry.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/samplecode/SampleCCPRGeometry.cpp b/samplecode/SampleCCPRGeometry.cpp index 4d4bfcf49e..c6174516d3 100644 --- a/samplecode/SampleCCPRGeometry.cpp +++ b/samplecode/SampleCCPRGeometry.cpp @@ -310,7 +310,7 @@ void CCPRGeometryView::DrawCoverageCountOp::drawRenderPass(GrOpFlushState* state SkDEBUGCODE(proc.enableDebugBloat(kDebugBloat)); SkSTArray<1, GrMesh> mesh; - if (RenderPass::kCubics == renderPass) { + if (GrCCCoverageProcessor::RenderPassIsCubic(renderPass)) { sk_sp<GrBuffer> instBuff(rp->createBuffer( fView->fQuadPointInstances.count() * sizeof(QuadPointInstance), kVertex_GrBufferType, kDynamic_GrAccessPattern, |