| OLD | NEW |
| 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 "GrPipeline.h" | 8 #include "GrPipeline.h" |
| 9 | 9 |
| 10 #include "GrCaps.h" | 10 #include "GrCaps.h" |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 const GrProcOptInfo& colorPOI, | 186 const GrProcOptInfo& colorPOI, |
| 187 const GrProcOptInfo& coveragePOI
, | 187 const GrProcOptInfo& coveragePOI
, |
| 188 int* firstColorProcessorIdx, | 188 int* firstColorProcessorIdx, |
| 189 int* firstCoverageProcessorIdx)
{ | 189 int* firstCoverageProcessorIdx)
{ |
| 190 fReadsFragPosition = fXferProcessor->willReadFragmentPosition(); | 190 fReadsFragPosition = fXferProcessor->willReadFragmentPosition(); |
| 191 | 191 |
| 192 if ((flags & GrXferProcessor::kIgnoreColor_OptFlag) || | 192 if ((flags & GrXferProcessor::kIgnoreColor_OptFlag) || |
| 193 (flags & GrXferProcessor::kOverrideColor_OptFlag)) { | 193 (flags & GrXferProcessor::kOverrideColor_OptFlag)) { |
| 194 *firstColorProcessorIdx = pipelineBuilder.numColorFragmentProcessors(); | 194 *firstColorProcessorIdx = pipelineBuilder.numColorFragmentProcessors(); |
| 195 } else { | 195 } else { |
| 196 if (coveragePOI.readsFragPosition()) { | 196 if (colorPOI.readsFragPosition()) { |
| 197 fReadsFragPosition = true; | 197 fReadsFragPosition = true; |
| 198 } | 198 } |
| 199 } | 199 } |
| 200 | 200 |
| 201 if (flags & GrXferProcessor::kIgnoreCoverage_OptFlag) { | 201 if (flags & GrXferProcessor::kIgnoreCoverage_OptFlag) { |
| 202 *firstCoverageProcessorIdx = pipelineBuilder.numCoverageFragmentProcesso
rs(); | 202 *firstCoverageProcessorIdx = pipelineBuilder.numCoverageFragmentProcesso
rs(); |
| 203 } else { | 203 } else { |
| 204 if (coveragePOI.readsFragPosition()) { | 204 if (coveragePOI.readsFragPosition()) { |
| 205 fReadsFragPosition = true; | 205 fReadsFragPosition = true; |
| 206 } | 206 } |
| (...skipping 21 matching lines...) Expand all Loading... |
| 228 } | 228 } |
| 229 | 229 |
| 230 for (int i = 0; i < a.numFragmentProcessors(); i++) { | 230 for (int i = 0; i < a.numFragmentProcessors(); i++) { |
| 231 if (!a.getFragmentProcessor(i).isEqual(b.getFragmentProcessor(i), ignore
CoordTransforms)) { | 231 if (!a.getFragmentProcessor(i).isEqual(b.getFragmentProcessor(i), ignore
CoordTransforms)) { |
| 232 return false; | 232 return false; |
| 233 } | 233 } |
| 234 } | 234 } |
| 235 return true; | 235 return true; |
| 236 } | 236 } |
| 237 | 237 |
| OLD | NEW |