Add processor name to comment when printing out shaders.

BUG=skia:

Review URL: https://codereview.chromium.org/735153002
This commit is contained in:
egdaniel 2014-11-19 06:22:39 -08:00 committed by Commit bot
parent b07a94f1cb
commit ec03a46080
2 changed files with 3 additions and 1 deletions

View File

@ -146,6 +146,8 @@ public:
}
}
const char* name() const { return fProc->name(); }
const GrFragmentProcessor* getProcessor() const { return fProc.get(); }
void convertToPendingExec() { fProc.convertToPendingExec(); }

View File

@ -296,7 +296,7 @@ void GrGLProgramBuilder::emitAndInstallProc(const Proc& proc,
// Enclose custom code in a block to avoid namespace conflicts
SkString openBrace;
openBrace.printf("{ // Stage %d\n", fStageIndex);
openBrace.printf("{ // Stage %d, %s\n", fStageIndex, proc.name());
fFS.codeAppend(openBrace.c_str());
this->emitAndInstallProc(proc, keyProvider.get(index), output->c_str(),