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

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

Issue 1997773002: Retract GrRenderTarget from GLProgramsTest (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: update Created 4 years, 7 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 | « include/gpu/GrProcessorUnitTest.h ('k') | tests/GLProgramsTest.cpp » ('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 "effects/GrCoverageSetOpXP.h" 8 #include "effects/GrCoverageSetOpXP.h"
9 #include "GrCaps.h" 9 #include "GrCaps.h"
10 #include "GrColor.h" 10 #include "GrColor.h"
11 #include "GrDrawContext.h"
11 #include "GrPipeline.h" 12 #include "GrPipeline.h"
12 #include "GrProcessor.h" 13 #include "GrProcessor.h"
13 #include "GrProcOptInfo.h" 14 #include "GrProcOptInfo.h"
14 #include "glsl/GrGLSLBlend.h" 15 #include "glsl/GrGLSLBlend.h"
15 #include "glsl/GrGLSLFragmentShaderBuilder.h" 16 #include "glsl/GrGLSLFragmentShaderBuilder.h"
16 #include "glsl/GrGLSLUniformHandler.h" 17 #include "glsl/GrGLSLUniformHandler.h"
17 #include "glsl/GrGLSLXferProcessor.h" 18 #include "glsl/GrGLSLXferProcessor.h"
18 19
19 class CoverageSetOpXP : public GrXferProcessor { 20 class CoverageSetOpXP : public GrXferProcessor {
20 public: 21 public:
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 void GrCoverageSetOpXPFactory::getInvariantBlendedColor(const GrProcOptInfo& col orPOI, 332 void GrCoverageSetOpXPFactory::getInvariantBlendedColor(const GrProcOptInfo& col orPOI,
332 InvariantBlendedColor* b lendedColor) const { 333 InvariantBlendedColor* b lendedColor) const {
333 blendedColor->fWillBlendWithDst = SkRegion::kReplace_Op != fRegionOp; 334 blendedColor->fWillBlendWithDst = SkRegion::kReplace_Op != fRegionOp;
334 blendedColor->fKnownColorFlags = kNone_GrColorComponentFlags; 335 blendedColor->fKnownColorFlags = kNone_GrColorComponentFlags;
335 } 336 }
336 337
337 GR_DEFINE_XP_FACTORY_TEST(GrCoverageSetOpXPFactory); 338 GR_DEFINE_XP_FACTORY_TEST(GrCoverageSetOpXPFactory);
338 339
339 const GrXPFactory* GrCoverageSetOpXPFactory::TestCreate(GrProcessorTestData* d) { 340 const GrXPFactory* GrCoverageSetOpXPFactory::TestCreate(GrProcessorTestData* d) {
340 SkRegion::Op regionOp = SkRegion::Op(d->fRandom->nextULessThan(SkRegion::kLa stOp + 1)); 341 SkRegion::Op regionOp = SkRegion::Op(d->fRandom->nextULessThan(SkRegion::kLa stOp + 1));
341 bool invertCoverage = !d->fRenderTarget->hasMixedSamples() && d->fRandom->ne xtBool(); 342 bool invertCoverage = !d->fDrawContext->hasMixedSamples() && d->fRandom->nex tBool();
342 return GrCoverageSetOpXPFactory::Create(regionOp, invertCoverage); 343 return GrCoverageSetOpXPFactory::Create(regionOp, invertCoverage);
343 } 344 }
OLDNEW
« no previous file with comments | « include/gpu/GrProcessorUnitTest.h ('k') | tests/GLProgramsTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698