aboutsummaryrefslogtreecommitdiffhomepage
path: root/gpu/src/GrGpuGLShaders2.cpp
diff options
context:
space:
mode:
authorGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2011-03-10 14:13:19 +0000
committerGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2011-03-10 14:13:19 +0000
commita7f84e150cb9e821267a8ca9e59c1ae9a3cfa300 (patch)
tree92d0c75a44d7ecfbb0a208fa6f9837ef071a8395 /gpu/src/GrGpuGLShaders2.cpp
parent63a6060fcdc16245ea3958e7fd88ae32c5e631a3 (diff)
Make flush discardable and lazily reset context
Review URL: http://codereview.appspot.com/4259059/ git-svn-id: http://skia.googlecode.com/svn/trunk@914 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'gpu/src/GrGpuGLShaders2.cpp')
-rw-r--r--gpu/src/GrGpuGLShaders2.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/gpu/src/GrGpuGLShaders2.cpp b/gpu/src/GrGpuGLShaders2.cpp
index 77847e9fba..f79e9c883a 100644
--- a/gpu/src/GrGpuGLShaders2.cpp
+++ b/gpu/src/GrGpuGLShaders2.cpp
@@ -1088,8 +1088,6 @@ void GrGpuGLShaders2::DeleteProgram(Program* program) {
GrGpuGLShaders2::GrGpuGLShaders2() {
- resetContextHelper();
-
fProgram = NULL;
fProgramCache = new ProgramCache();
@@ -1119,11 +1117,9 @@ void GrGpuGLShaders2::recordHWSamplerMatrix(int stage, const GrMatrix& matrix){
}
void GrGpuGLShaders2::resetContext() {
+
INHERITED::resetContext();
- resetContextHelper();
-}
-void GrGpuGLShaders2::resetContextHelper() {
fHWGeometryState.fVertexLayout = 0;
fHWGeometryState.fVertexOffset = ~0;
GR_GL(DisableVertexAttribArray(COL_ATTR_LOCATION));