Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(219)

Unified Diff: src/gpu/GrOptDrawState.cpp

Issue 851143003: Remove willReadDst from GrFragmentProcessor. (Closed) Base URL: https://skia.googlesource.com/skia.git@xferXP
Patch Set: Rebase Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrDrawTarget.cpp ('k') | src/gpu/GrProcOptInfo.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrOptDrawState.cpp
diff --git a/src/gpu/GrOptDrawState.cpp b/src/gpu/GrOptDrawState.cpp
index 742ffade125f8b448af7ea6a3487396ea8d486af..bc1ce7dc930258052749c203fde00296401dd236 100644
--- a/src/gpu/GrOptDrawState.cpp
+++ b/src/gpu/GrOptDrawState.cpp
@@ -89,6 +89,8 @@ GrOptDrawState::GrOptDrawState(const GrDrawState& drawState,
this->adjustProgramFromOptimizations(drawState, optFlags, colorPOI, coveragePOI,
&firstColorStageIdx, &firstCoverageStageIdx);
+ fDescInfo.fReadsDst = fXferProcessor->willReadDstColor();
+
bool usesLocalCoords = false;
// Copy Stages from DS to ODS
@@ -124,31 +126,22 @@ void GrOptDrawState::adjustProgramFromOptimizations(const GrDrawState& ds,
const GrProcOptInfo& coveragePOI,
int* firstColorStageIdx,
int* firstCoverageStageIdx) {
- fDescInfo.fReadsDst = false;
fDescInfo.fReadsFragPosition = false;
if ((flags & GrXferProcessor::kIgnoreColor_OptFlag) ||
(flags & GrXferProcessor::kOverrideColor_OptFlag)) {
*firstColorStageIdx = ds.numColorStages();
} else {
- fDescInfo.fReadsDst = colorPOI.readsDst();
fDescInfo.fReadsFragPosition = colorPOI.readsFragPosition();
}
if (flags & GrXferProcessor::kIgnoreCoverage_OptFlag) {
*firstCoverageStageIdx = ds.numCoverageStages();
} else {
- if (coveragePOI.readsDst()) {
- fDescInfo.fReadsDst = true;
- }
if (coveragePOI.readsFragPosition()) {
fDescInfo.fReadsFragPosition = true;
}
}
-
- if (fXferProcessor->willReadDstColor()) {
- fDescInfo.fReadsDst = true;
- }
}
void GrOptDrawState::finalize(GrGpu* gpu) {
« no previous file with comments | « src/gpu/GrDrawTarget.cpp ('k') | src/gpu/GrProcOptInfo.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698