Implement dirty bits for RendererGL's basic state.

BUG=angleproject:1040
TEST=angle_end2end_tests,angle_perftests,WebGL

Change-Id: I72beaf7e178e042440337fbb8b9669638c5ad016
Reviewed-on: https://chromium-review.googlesource.com/289558
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Tested-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/libANGLE/Framebuffer.h b/src/libANGLE/Framebuffer.h
index 428789c..3b132a3 100644
--- a/src/libANGLE/Framebuffer.h
+++ b/src/libANGLE/Framebuffer.h
@@ -32,6 +32,7 @@
 
 namespace gl
 {
+class Context;
 class Renderbuffer;
 class State;
 class Texture;
@@ -121,15 +122,23 @@
     Error invalidate(size_t count, const GLenum *attachments);
     Error invalidateSub(size_t count, const GLenum *attachments, const gl::Rectangle &area);
 
-    Error clear(const gl::Data &data, GLbitfield mask);
-    Error clearBufferfv(const State &state, GLenum buffer, GLint drawbuffer, const GLfloat *values);
-    Error clearBufferuiv(const State &state, GLenum buffer, GLint drawbuffer, const GLuint *values);
-    Error clearBufferiv(const State &state, GLenum buffer, GLint drawbuffer, const GLint *values);
-    Error clearBufferfi(const State &state, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+    Error clear(Context *context, GLbitfield mask);
+    Error clearBufferfv(Context *context, GLenum buffer, GLint drawbuffer, const GLfloat *values);
+    Error clearBufferuiv(Context *context, GLenum buffer, GLint drawbuffer, const GLuint *values);
+    Error clearBufferiv(Context *context, GLenum buffer, GLint drawbuffer, const GLint *values);
+    Error clearBufferfi(Context *context,
+                        GLenum buffer,
+                        GLint drawbuffer,
+                        GLfloat depth,
+                        GLint stencil);
 
     GLenum getImplementationColorReadFormat() const;
     GLenum getImplementationColorReadType() const;
-    Error readPixels(const gl::State &state, const gl::Rectangle &area, GLenum format, GLenum type, GLvoid *pixels) const;
+    Error readPixels(Context *context,
+                     const gl::Rectangle &area,
+                     GLenum format,
+                     GLenum type,
+                     GLvoid *pixels) const;
 
     Error blit(const gl::State &state, const gl::Rectangle &sourceArea, const gl::Rectangle &destArea,
                GLbitfield mask, GLenum filter, const gl::Framebuffer *sourceFramebuffer);