diff options
author | 2014-10-21 07:47:10 -0700 | |
---|---|---|
committer | 2014-10-21 07:47:10 -0700 | |
commit | c0651c14ed9dc9015d8882885ee42a3c572e8e7e (patch) | |
tree | af25fe170c79a9ee9bf481b0cc4ef7a438d64e74 | |
parent | bf5473b218c88ad8d28d477603739a868917e2e0 (diff) |
Add check to see if we need to remove fixed funciton VA in OptDrawState
BUG=skia:
Review URL: https://codereview.chromium.org/667033003
-rw-r--r-- | src/gpu/GrOptDrawState.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gpu/GrOptDrawState.cpp b/src/gpu/GrOptDrawState.cpp index 40e0c6ce1f..77a9fc8dc4 100644 --- a/src/gpu/GrOptDrawState.cpp +++ b/src/gpu/GrOptDrawState.cpp @@ -48,7 +48,9 @@ GrOptDrawState::GrOptDrawState(const GrDrawState& drawState, this->adjustFromBlendOpts(drawState, &firstColorStageIdx, &firstCoverageStageIdx, &fixedFunctionVAToRemove); // Should not be setting any more FFVA to be removed at this point - this->removeFixedFunctionVertexAttribs(fixedFunctionVAToRemove); + if (0 != fixedFunctionVAToRemove) { + this->removeFixedFunctionVertexAttribs(fixedFunctionVAToRemove); + } this->getStageStats(drawState, firstColorStageIdx, firstCoverageStageIdx); this->setOutputStateInfo(drawState, caps, firstCoverageStageIdx, &separateCoverageFromColor); |