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

Side by Side Diff: src/gpu/GrAALinearizingConvexPathRenderer.cpp

Issue 1229143007: Start to propagate constness of GrPipelineBuilder up the stack (Closed) Base URL: https://skia.googlesource.com/skia.git@const-fix
Patch Set: rebase Created 5 years, 5 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/GrAAHairLinePathRenderer.cpp ('k') | src/gpu/GrAARectRenderer.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 /* 2 /*
3 * Copyright 2015 Google Inc. 3 * Copyright 2015 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "GrAALinearizingConvexPathRenderer.h" 9 #include "GrAALinearizingConvexPathRenderer.h"
10 10
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 } 311 }
312 AAFlatteningConvexPathBatch::Geometry geometry; 312 AAFlatteningConvexPathBatch::Geometry geometry;
313 geometry.fColor = color; 313 geometry.fColor = color;
314 geometry.fViewMatrix = vm; 314 geometry.fViewMatrix = vm;
315 geometry.fPath = path; 315 geometry.fPath = path;
316 geometry.fStrokeWidth = stroke.isFillStyle() ? -1.0f : stroke.getWidth(); 316 geometry.fStrokeWidth = stroke.isFillStyle() ? -1.0f : stroke.getWidth();
317 geometry.fJoin = stroke.isFillStyle() ? SkPaint::Join::kMiter_Join : stroke. getJoin(); 317 geometry.fJoin = stroke.isFillStyle() ? SkPaint::Join::kMiter_Join : stroke. getJoin();
318 geometry.fMiterLimit = stroke.getMiter(); 318 geometry.fMiterLimit = stroke.getMiter();
319 319
320 SkAutoTUnref<GrBatch> batch(AAFlatteningConvexPathBatch::Create(geometry)); 320 SkAutoTUnref<GrBatch> batch(AAFlatteningConvexPathBatch::Create(geometry));
321 target->drawBatch(pipelineBuilder, batch); 321 target->drawBatch(*pipelineBuilder, batch);
322 322
323 return true; 323 return true;
324 } 324 }
325 325
326 //////////////////////////////////////////////////////////////////////////////// /////////////////// 326 //////////////////////////////////////////////////////////////////////////////// ///////////////////
327 327
328 #ifdef GR_TEST_UTILS 328 #ifdef GR_TEST_UTILS
329 329
330 BATCH_TEST_DEFINE(AAFlatteningConvexPathBatch) { 330 BATCH_TEST_DEFINE(AAFlatteningConvexPathBatch) {
331 AAFlatteningConvexPathBatch::Geometry geometry; 331 AAFlatteningConvexPathBatch::Geometry geometry;
332 geometry.fColor = GrRandomColor(random); 332 geometry.fColor = GrRandomColor(random);
333 geometry.fViewMatrix = GrTest::TestMatrixInvertible(random); 333 geometry.fViewMatrix = GrTest::TestMatrixInvertible(random);
334 geometry.fPath = GrTest::TestPathConvex(random); 334 geometry.fPath = GrTest::TestPathConvex(random);
335 335
336 return AAFlatteningConvexPathBatch::Create(geometry); 336 return AAFlatteningConvexPathBatch::Create(geometry);
337 } 337 }
338 338
339 #endif 339 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrAAHairLinePathRenderer.cpp ('k') | src/gpu/GrAARectRenderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698