Index: src/gpu/GrOptDrawState.cpp |
diff --git a/src/gpu/GrOptDrawState.cpp b/src/gpu/GrOptDrawState.cpp |
index 7c8710f7d6466fd8d6432732c0af904132a2f0b4..b3d90f7310204f7958a2a29fb42050e640c11a0c 100644 |
--- a/src/gpu/GrOptDrawState.cpp |
+++ b/src/gpu/GrOptDrawState.cpp |
@@ -54,7 +54,7 @@ |
// Copy GeometryProcesssor from DS or ODS |
if (drawState.hasGeometryProcessor()) { |
- fGeometryProcessor.initAndRef(drawState.fGeometryProcessor); |
+ fGeometryProcessor.reset(SkNEW_ARGS(GrGeometryStage, (*drawState.getGeometryProcessor()))); |
} else { |
fGeometryProcessor.reset(NULL); |
} |
@@ -305,8 +305,8 @@ |
get_stage_stats(stage, &fReadsDst, &fReadsFragPosition); |
} |
if (ds.hasGeometryProcessor()) { |
- const GrGeometryProcessor& gp = *ds.getGeometryProcessor(); |
- fReadsFragPosition = fReadsFragPosition || gp.willReadFragmentPosition(); |
+ const GrGeometryStage& stage = *ds.getGeometryProcessor(); |
+ fReadsFragPosition = fReadsFragPosition || stage.getProcessor()->willReadFragmentPosition(); |
} |
} |
@@ -354,7 +354,9 @@ |
if (this->hasGeometryProcessor()) { |
if (!that.hasGeometryProcessor()) { |
return false; |
- } else if (!this->getGeometryProcessor()->isEqual(*that.getGeometryProcessor())) { |
+ } else if (!GrProcessorStage::AreCompatible(*this->getGeometryProcessor(), |
+ *that.getGeometryProcessor(), |
+ explicitLocalCoords)) { |
return false; |
} |
} else if (that.hasGeometryProcessor()) { |
@@ -362,8 +364,8 @@ |
} |
for (int i = 0; i < this->numFragmentStages(); i++) { |
- if (!GrFragmentStage::AreCompatible(this->getFragmentStage(i), that.getFragmentStage(i), |
- explicitLocalCoords)) { |
+ if (!GrProcessorStage::AreCompatible(this->getFragmentStage(i), that.getFragmentStage(i), |
+ explicitLocalCoords)) { |
return false; |
} |
} |