Index: src/gpu/GrOptDrawState.cpp |
diff --git a/src/gpu/GrOptDrawState.cpp b/src/gpu/GrOptDrawState.cpp |
index 7d8b06c129cbb570d45d8622dd4483fcd3a5f47c..6874ea7afc3481dff300cefa7750f7b694f8c2e8 100644 |
--- a/src/gpu/GrOptDrawState.cpp |
+++ b/src/gpu/GrOptDrawState.cpp |
@@ -11,7 +11,7 @@ |
#include "GrDrawState.h" |
#include "GrDrawTargetCaps.h" |
#include "GrGpu.h" |
-#include "GrInvariantOutput.h" |
+#include "GrProcOptInfo.h" |
GrOptDrawState::GrOptDrawState(const GrDrawState& drawState, |
BlendOptFlags blendOptFlags, |
@@ -239,8 +239,17 @@ void GrOptDrawState::computeEffectiveColorStages(const GrDrawState& ds, |
color = 0; |
} |
} |
- GrInvariantOutput inout(color, flags, false); |
- |
+ GrProcOptInfo poi; |
+ if (ds.numColorStages() > 0) { |
+ poi.calcWithInitialValues(&ds.getColorStage(0), ds.numColorStages(), color, flags, false); |
+ *firstColorStageIdx = poi.firstEffectiveStageIndex(); |
+ descInfo->fInputColorIsUsed = poi.inputColorIsUsed(); |
+ fColor = poi.inputColorToEffectiveStage(); |
+ if (poi.removeVertexAttrib()) { |
+ *fixedFunctionVAToRemove |= 0x1 << kColor_GrVertexAttribBinding; |
+ } |
+ } |
+/* |
for (int i = 0; i < ds.numColorStages(); ++i) { |
const GrFragmentProcessor* fp = ds.getColorStage(i).getProcessor(); |
fp->computeInvariantOutput(&inout); |
@@ -258,6 +267,7 @@ void GrOptDrawState::computeEffectiveColorStages(const GrDrawState& ds, |
inout.resetNonMulStageFound(); |
} |
} |
+ */ |
} |
void GrOptDrawState::computeEffectiveCoverageStages(const GrDrawState& ds, |