| Index: src/gpu/gl/builders/GrGLProgramBuilder.cpp
|
| diff --git a/src/gpu/gl/builders/GrGLProgramBuilder.cpp b/src/gpu/gl/builders/GrGLProgramBuilder.cpp
|
| index 4360f7858d2129171fb19382dfb02bb0e1e64d34..8928dfef4a4bd0e31f8789099f0f0adf5cf3107f 100644
|
| --- a/src/gpu/gl/builders/GrGLProgramBuilder.cpp
|
| +++ b/src/gpu/gl/builders/GrGLProgramBuilder.cpp
|
| @@ -94,9 +94,12 @@ bool GrGLProgramBuilder::emitAndInstallProcs(GrGLSLExpr4* inputColor, GrGLSLExpr
|
| this->emitAndInstallFragProcs(0, this->pipeline().numColorFragmentProcessors(), inputColor);
|
| this->emitAndInstallFragProcs(this->pipeline().numColorFragmentProcessors(), numProcs,
|
| inputCoverage);
|
| - this->emitAndInstallXferProc(this->pipeline().getXferProcessor(), *inputColor, *inputCoverage,
|
| - this->pipeline().ignoresCoverage());
|
| - this->emitFSOutputSwizzle(this->pipeline().getXferProcessor().hasSecondaryOutput());
|
| + if (primProc.getPixelLocalStorageState() != GrPixelLocalStorageState::kDraw_State) {
|
| + this->emitAndInstallXferProc(this->pipeline().getXferProcessor(), *inputColor,
|
| + *inputCoverage, this->pipeline().ignoresCoverage(),
|
| + primProc.getPixelLocalStorageState());
|
| + this->emitFSOutputSwizzle(this->pipeline().getXferProcessor().hasSecondaryOutput());
|
| + }
|
| return true;
|
| }
|
|
|
| @@ -223,7 +226,8 @@ void GrGLProgramBuilder::emitAndInstallProc(const GrPrimitiveProcessor& gp,
|
| void GrGLProgramBuilder::emitAndInstallXferProc(const GrXferProcessor& xp,
|
| const GrGLSLExpr4& colorIn,
|
| const GrGLSLExpr4& coverageIn,
|
| - bool ignoresCoverage) {
|
| + bool ignoresCoverage,
|
| + GrPixelLocalStorageState plsState) {
|
| // Program builders have a bit of state we need to clear with each effect
|
| AutoStageAdvance adv(this);
|
|
|
| @@ -255,7 +259,8 @@ void GrGLProgramBuilder::emitAndInstallXferProc(const GrXferProcessor& xp,
|
| ignoresCoverage ? nullptr : coverageIn.c_str(),
|
| fFS.getPrimaryColorOutputName(),
|
| fFS.getSecondaryColorOutputName(),
|
| - samplers);
|
| + samplers,
|
| + plsState == GrPixelLocalStorageState::kFinish_State);
|
| fXferProcessor->fGLProc->emitCode(args);
|
|
|
| // We have to check that effects and the code they emit are consistent, ie if an effect
|
|
|