Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(97)

Side by Side Diff: src/gpu/effects/GrDashingEffect.cpp

Issue 1541903002: added support for PLS path rendering (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix for ASAN failure Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/gpu/effects/GrCustomXfermode.cpp ('k') | src/gpu/effects/GrDisableColorXP.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "GrDashingEffect.h" 8 #include "GrDashingEffect.h"
9 9
10 #include "GrBatchFlushState.h" 10 #include "GrBatchFlushState.h"
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 } 268 }
269 269
270 const char* name() const override { return "DashBatch"; } 270 const char* name() const override { return "DashBatch"; }
271 271
272 void computePipelineOptimizations(GrInitInvariantOutput* color, 272 void computePipelineOptimizations(GrInitInvariantOutput* color,
273 GrInitInvariantOutput* coverage, 273 GrInitInvariantOutput* coverage,
274 GrBatchToXPOverrides* overrides) const ove rride { 274 GrBatchToXPOverrides* overrides) const ove rride {
275 // When this is called on a batch, there is only one geometry bundle 275 // When this is called on a batch, there is only one geometry bundle
276 color->setKnownFourComponents(fGeoData[0].fColor); 276 color->setKnownFourComponents(fGeoData[0].fColor);
277 coverage->setUnknownSingleComponent(); 277 coverage->setUnknownSingleComponent();
278 overrides->fUsePLSDstRead = false;
279 } 278 }
280 279
281 SkSTArray<1, Geometry, true>* geoData() { return &fGeoData; } 280 SkSTArray<1, Geometry, true>* geoData() { return &fGeoData; }
282 281
283 private: 282 private:
284 DashBatch(const Geometry& geometry, SkPaint::Cap cap, DashAAMode aaMode, boo l fullDash) 283 DashBatch(const Geometry& geometry, SkPaint::Cap cap, DashAAMode aaMode, boo l fullDash)
285 : INHERITED(ClassID()) { 284 : INHERITED(ClassID()) {
286 fGeoData.push_back(geometry); 285 fGeoData.push_back(geometry);
287 286
288 fBatch.fAAMode = aaMode; 287 fBatch.fAAMode = aaMode;
(...skipping 1018 matching lines...) Expand 10 before | Expand all | Expand 10 after
1307 info.fIntervals = intervals; 1306 info.fIntervals = intervals;
1308 info.fCount = 2; 1307 info.fCount = 2;
1309 info.fPhase = phase; 1308 info.fPhase = phase;
1310 SkDEBUGCODE(bool success = ) strokeInfo.setDashInfo(info); 1309 SkDEBUGCODE(bool success = ) strokeInfo.setDashInfo(info);
1311 SkASSERT(success); 1310 SkASSERT(success);
1312 1311
1313 return create_batch(color, viewMatrix, pts, useAA, strokeInfo, msaaRT); 1312 return create_batch(color, viewMatrix, pts, useAA, strokeInfo, msaaRT);
1314 } 1313 }
1315 1314
1316 #endif 1315 #endif
OLDNEW
« no previous file with comments | « src/gpu/effects/GrCustomXfermode.cpp ('k') | src/gpu/effects/GrDisableColorXP.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698