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

Unified Diff: src/gpu/gl/builders/GrGLProgramBuilder.h

Issue 674543004: OptState owns program descriptor (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: feedback inc Created 6 years, 2 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
Index: src/gpu/gl/builders/GrGLProgramBuilder.h
diff --git a/src/gpu/gl/builders/GrGLProgramBuilder.h b/src/gpu/gl/builders/GrGLProgramBuilder.h
index 2afdd099f4322abf2246bedb0181137159808df0..d1501716267b1612757f04611f787bad8b2ffebb 100644
--- a/src/gpu/gl/builders/GrGLProgramBuilder.h
+++ b/src/gpu/gl/builders/GrGLProgramBuilder.h
@@ -119,10 +119,7 @@ public:
* to be used.
* @return true if generation was successful.
*/
- static GrGLProgram* CreateProgram(const GrOptDrawState&,
- const GrGLProgramDesc&,
- GrGpu::DrawType,
- GrGpuGL* gpu);
+ static GrGLProgram* CreateProgram(const GrOptDrawState&, GrGpu::DrawType, GrGpuGL*);
virtual UniformHandle addUniform(uint32_t visibility,
GrSLType type,
@@ -176,21 +173,20 @@ public:
};
protected:
- typedef GrGLProgramDesc::ProcKeyProvider ProcKeyProvider;
+ typedef GrProgramDesc::ProcKeyProvider ProcKeyProvider;
typedef GrGLProgramDataManager::UniformInfo UniformInfo;
typedef GrGLProgramDataManager::UniformInfoArray UniformInfoArray;
- static GrGLProgramBuilder* CreateProgramBuilder(const GrGLProgramDesc&,
- const GrOptDrawState&,
+ static GrGLProgramBuilder* CreateProgramBuilder(const GrOptDrawState&,
GrGpu::DrawType,
bool hasGeometryProcessor,
GrGpuGL*);
- GrGLProgramBuilder(GrGpuGL*, const GrOptDrawState&, const GrGLProgramDesc&);
+ GrGLProgramBuilder(GrGpuGL*, const GrOptDrawState&);
const GrOptDrawState& optState() const { return fOptState; }
- const GrGLProgramDesc& desc() const { return fDesc; }
- const GrGLProgramDesc::KeyHeader& header() const { return fDesc.getHeader(); }
+ const GrProgramDesc& desc() const { return fDesc; }
+ const GrProgramDesc::KeyHeader& header() const { return fDesc.header(); }
// Generates a name for a variable. The generated string will be name prefixed by the prefix
// char (unless the prefix is '\0'). It also mangles the name to be stage-specific if we're
@@ -204,7 +200,7 @@ protected:
template <class Proc>
void emitAndInstallProc(const Proc&,
int index,
- const ProcKeyProvider,
+ const ProcKeyProvider&,
const GrGLSLExpr4& input,
GrGLSLExpr4* output);
@@ -284,7 +280,7 @@ protected:
SkAutoTUnref<GrGLInstalledFragProcs> fFragmentProcessors;
const GrOptDrawState& fOptState;
- const GrGLProgramDesc& fDesc;
+ const GrProgramDesc& fDesc;
GrGpuGL* fGpu;
UniformInfoArray fUniforms;

Powered by Google App Engine
This is Rietveld 408576698