Index: src/gpu/gl/GrGLShaderBuilder.h |
diff --git a/src/gpu/gl/GrGLShaderBuilder.h b/src/gpu/gl/GrGLShaderBuilder.h |
index 3a93c1bf72e33e944c36403d06d8c9c975a32b65..7e71acf901f8e78df6a1bb3c32c89e8c98810b35 100644 |
--- a/src/gpu/gl/GrGLShaderBuilder.h |
+++ b/src/gpu/gl/GrGLShaderBuilder.h |
@@ -68,12 +68,26 @@ public: |
, fTexCoordSetCnt(0) |
, fProgramID(0) {} |
- GrGLProgramEffects* fColorEffects; |
- GrGLProgramEffects* fCoverageEffects; |
- UniformHandles fUniformHandles; |
- bool fHasVertexShader; |
- int fTexCoordSetCnt; |
- GrGLuint fProgramID; |
+ GenProgramOutput(const GenProgramOutput& other) { |
+ *this = other; |
+ } |
+ |
+ GenProgramOutput& operator=(const GenProgramOutput& other) { |
+ fColorEffects.reset(SkRef(other.fColorEffects.get())); |
+ fCoverageEffects.reset(SkRef(other.fCoverageEffects.get())); |
+ fUniformHandles = other.fUniformHandles; |
+ fHasVertexShader = other.fHasVertexShader; |
+ fTexCoordSetCnt = other.fTexCoordSetCnt; |
+ fProgramID = other.fProgramID; |
+ return *this; |
+ } |
+ |
+ SkAutoTUnref<GrGLProgramEffects> fColorEffects; |
+ SkAutoTUnref<GrGLProgramEffects> fCoverageEffects; |
+ UniformHandles fUniformHandles; |
+ bool fHasVertexShader; |
+ int fTexCoordSetCnt; |
+ GrGLuint fProgramID; |
}; |
static bool GenProgram(GrGpuGL* gpu, |