Index: gpu/command_buffer/service/error_state.h |
=================================================================== |
--- gpu/command_buffer/service/error_state.h (revision 261814) |
+++ gpu/command_buffer/service/error_state.h (working copy) |
@@ -55,12 +55,17 @@ |
#define ERRORSTATE_CLEAR_REAL_GL_ERRORS(error_state, function_name) \ |
error_state->ClearRealGLErrors(__FILE__, __LINE__, function_name) |
+class GPU_EXPORT ErrorStateClient { |
+ public: |
+ // GL_OUT_OF_MEMORY can cause side effects such as losing the context. |
+ virtual void OnOutOfMemoryError() = 0; |
+}; |
class GPU_EXPORT ErrorState { |
public: |
virtual ~ErrorState(); |
- static ErrorState* Create(Logger* logger); |
+ static ErrorState* Create(ErrorStateClient* client, Logger* logger); |
virtual uint32 GetGLError() = 0; |