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

Side by Side Diff: tests/GrPorterDuffTest.cpp

Issue 1483103003: Make onPrepareDraws const (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years 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
OLDNEW
1 /* 1 /*
2 * Copyright 2015 Google Inc. 2 * Copyright 2015 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 "SkXfermode.h" 8 #include "SkXfermode.h"
9 #include "Test.h" 9 #include "Test.h"
10 10
(...skipping 1094 matching lines...) Expand 10 before | Expand all | Expand 10 after
1105 } 1105 }
1106 1106
1107 void getInvariantOutputCoverage(GrInitInvariantOutput* out) const overri de { 1107 void getInvariantOutputCoverage(GrInitInvariantOutput* out) const overri de {
1108 out->setUnknownFourComponents(); 1108 out->setUnknownFourComponents();
1109 out->setUsingLCDCoverage(); 1109 out->setUsingLCDCoverage();
1110 } 1110 }
1111 1111
1112 const char* name() const override { return "Test LCD Text Batch"; } 1112 const char* name() const override { return "Test LCD Text Batch"; }
1113 void initBatchTracker(const GrPipelineOptimizations&) override {} 1113 void initBatchTracker(const GrPipelineOptimizations&) override {}
1114 bool onCombineIfPossible(GrBatch*, const GrCaps&) override { return fal se; } 1114 bool onCombineIfPossible(GrBatch*, const GrCaps&) override { return fal se; }
1115 void onPrepareDraws(Target*) override {}; 1115 void onPrepareDraws(Target*) const override {};
1116 1116
1117 typedef GrVertexBatch INHERITED; 1117 typedef GrVertexBatch INHERITED;
1118 } testLCDCoverageBatch; 1118 } testLCDCoverageBatch;
1119 1119
1120 GrProcOptInfo colorPOI, covPOI; 1120 GrProcOptInfo colorPOI, covPOI;
1121 colorPOI.calcColorWithBatch(&testLCDCoverageBatch, nullptr, 0); 1121 colorPOI.calcColorWithBatch(&testLCDCoverageBatch, nullptr, 0);
1122 covPOI.calcCoverageWithBatch(&testLCDCoverageBatch, nullptr, 0); 1122 covPOI.calcCoverageWithBatch(&testLCDCoverageBatch, nullptr, 0);
1123 1123
1124 SkASSERT(kRGBA_GrColorComponentFlags == colorPOI.validFlags()); 1124 SkASSERT(kRGBA_GrColorComponentFlags == colorPOI.validFlags());
1125 SkASSERT(covPOI.isFourChannelOutput()); 1125 SkASSERT(covPOI.isFourChannelOutput());
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
1213 xp->getOptimizations(colorPOI, covPOI, false, 0, caps); 1213 xp->getOptimizations(colorPOI, covPOI, false, 0, caps);
1214 TEST_ASSERT(!xp->hasSecondaryOutput()); 1214 TEST_ASSERT(!xp->hasSecondaryOutput());
1215 } 1215 }
1216 } 1216 }
1217 } 1217 }
1218 ctx->getGpu()->deleteTestingOnlyBackendTexture(backendTex); 1218 ctx->getGpu()->deleteTestingOnlyBackendTexture(backendTex);
1219 } 1219 }
1220 1220
1221 #endif 1221 #endif
1222 1222
OLDNEW
« src/gpu/batches/GrNonAAStrokeRectBatch.cpp ('K') | « src/gpu/effects/GrDashingEffect.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698