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

Unified Diff: ui/gl/gl_gl_api_implementation.h

Issue 104833007: Restore only modified texture state during virtual context switches (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More cleanup Created 7 years 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
« no previous file with comments | « ui/gl/gl.gyp ('k') | ui/gl/gl_gl_api_implementation.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/gl_gl_api_implementation.h
diff --git a/ui/gl/gl_gl_api_implementation.h b/ui/gl/gl_gl_api_implementation.h
index d925b939909c8bd1a51058f31c2a8de1b4390beb..7a9acf37593dc3a01ded3b6fcd7356a60c4eb90b 100644
--- a/ui/gl/gl_gl_api_implementation.h
+++ b/ui/gl/gl_gl_api_implementation.h
@@ -6,6 +6,7 @@
#define UI_GL_GL_API_IMPLEMENTATION_H_
#include "base/compiler_specific.h"
+#include "ui/gl/dirty_texture_state.h"
#include "ui/gl/gl_bindings.h"
#include "ui/gl/gl_export.h"
@@ -80,8 +81,13 @@ class GL_EXPORT VirtualGLApi : public GLApiBase {
// Overridden functions from GLApiBase
virtual const GLubyte* glGetStringFn(GLenum name) OVERRIDE;
+ virtual void glActiveTextureFn(GLenum texture) OVERRIDE;
+ virtual void glBindTextureFn(GLenum target, GLuint texture) OVERRIDE;
private:
+ // Clears the dirty texture state associated with this virtual context.
+ void ClearDirtyTextureState();
+
// The real context we're running on.
GLContext* real_context_;
@@ -90,6 +96,12 @@ class GL_EXPORT VirtualGLApi : public GLApiBase {
// The supported extensions being advertised for this virtual context.
std::string extensions_;
+
+ // Current active texture unit.
+ GLenum current_active_texture_unit_;
+
+ // The texture state that has been modified by this virtual context.
+ DirtyTextureState dirty_texture_state_;
};
} // namespace gfx
« no previous file with comments | « ui/gl/gl.gyp ('k') | ui/gl/gl_gl_api_implementation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698