| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 "GrDrawState.h" | 8 #include "GrDrawState.h" |
| 9 | 9 |
| 10 #include "GrBlend.h" | 10 #include "GrBlend.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 if (this->hasGeometryProcessor()) { | 44 if (this->hasGeometryProcessor()) { |
| 45 if (!that.hasGeometryProcessor()) { | 45 if (!that.hasGeometryProcessor()) { |
| 46 return false; | 46 return false; |
| 47 } else if (!this->getGeometryProcessor()->isEqual(*that.getGeometryProce
ssor())) { | 47 } else if (!this->getGeometryProcessor()->isEqual(*that.getGeometryProce
ssor())) { |
| 48 return false; | 48 return false; |
| 49 } | 49 } |
| 50 } else if (that.hasGeometryProcessor()) { | 50 } else if (that.hasGeometryProcessor()) { |
| 51 return false; | 51 return false; |
| 52 } | 52 } |
| 53 | 53 |
| 54 if (!this->getXPFactory()->isEqual(*that.getXPFactory())) { |
| 55 return false; |
| 56 } |
| 57 |
| 54 for (int i = 0; i < this->numColorStages(); i++) { | 58 for (int i = 0; i < this->numColorStages(); i++) { |
| 55 if (!GrFragmentStage::AreCompatible(this->getColorStage(i), that.getColo
rStage(i), | 59 if (!GrFragmentStage::AreCompatible(this->getColorStage(i), that.getColo
rStage(i), |
| 56 explicitLocalCoords)) { | 60 explicitLocalCoords)) { |
| 57 return false; | 61 return false; |
| 58 } | 62 } |
| 59 } | 63 } |
| 60 for (int i = 0; i < this->numCoverageStages(); i++) { | 64 for (int i = 0; i < this->numCoverageStages(); i++) { |
| 61 if (!GrFragmentStage::AreCompatible(this->getCoverageStage(i), that.getC
overageStage(i), | 65 if (!GrFragmentStage::AreCompatible(this->getCoverageStage(i), that.getC
overageStage(i), |
| 62 explicitLocalCoords)) { | 66 explicitLocalCoords)) { |
| 63 return false; | 67 return false; |
| (...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 551 } else { | 555 } else { |
| 552 flags = kRGBA_GrColorComponentFlags; | 556 flags = kRGBA_GrColorComponentFlags; |
| 553 color = this->getCoverageColor(); | 557 color = this->getCoverageColor(); |
| 554 } | 558 } |
| 555 fCoverageProcInfo.calcWithInitialValues(fCoverageStages.begin(), this->n
umCoverageStages(), | 559 fCoverageProcInfo.calcWithInitialValues(fCoverageStages.begin(), this->n
umCoverageStages(), |
| 556 color, flags, true, fGeometryPro
cessor.get()); | 560 color, flags, true, fGeometryPro
cessor.get()); |
| 557 fCoverageProcInfoValid = true; | 561 fCoverageProcInfoValid = true; |
| 558 } | 562 } |
| 559 } | 563 } |
| 560 | 564 |
| OLD | NEW |