| Index: gpu/command_buffer/client/gles2_implementation.h
|
| diff --git a/gpu/command_buffer/client/gles2_implementation.h b/gpu/command_buffer/client/gles2_implementation.h
|
| index 5e73c4da6c7ab1afdc1c43c6b99e306b5592095b..6ee901e2a05cb73a8f56c3556d51403e7ece9349 100644
|
| --- a/gpu/command_buffer/client/gles2_implementation.h
|
| +++ b/gpu/command_buffer/client/gles2_implementation.h
|
| @@ -26,7 +26,6 @@
|
| #include "gpu/command_buffer/client/context_support.h"
|
| #include "gpu/command_buffer/client/gles2_impl_export.h"
|
| #include "gpu/command_buffer/client/gles2_interface.h"
|
| -#include "gpu/command_buffer/client/gpu_control_client.h"
|
| #include "gpu/command_buffer/client/mapped_memory.h"
|
| #include "gpu/command_buffer/client/ref_counted.h"
|
| #include "gpu/command_buffer/client/share_group.h"
|
| @@ -112,6 +111,12 @@
|
| class VertexArrayObjectManager;
|
| class QueryTracker;
|
|
|
| +class GLES2ImplementationErrorMessageCallback {
|
| + public:
|
| + virtual ~GLES2ImplementationErrorMessageCallback() { }
|
| + virtual void OnErrorMessage(const char* msg, int id) = 0;
|
| +};
|
| +
|
| // This class emulates GLES2 over command buffers. It can be used by a client
|
| // program so that the program does not need deal with shared memory and command
|
| // buffer management. See gl2_lib.h. Note that there is a performance gain to
|
| @@ -121,7 +126,6 @@
|
| class GLES2_IMPL_EXPORT GLES2Implementation
|
| : NON_EXPORTED_BASE(public GLES2Interface),
|
| NON_EXPORTED_BASE(public ContextSupport),
|
| - NON_EXPORTED_BASE(public GpuControlClient),
|
| NON_EXPORTED_BASE(public base::trace_event::MemoryDumpProvider) {
|
| public:
|
| enum MappedMemoryLimit {
|
| @@ -208,10 +212,6 @@
|
| const gfx::Rect& display_bounds,
|
| const gfx::RectF& uv_rect) override;
|
| uint64_t ShareGroupTracingGUID() const override;
|
| -
|
| - void SetErrorMessageCallback(
|
| - const base::Callback<void(const char*, int32_t)>& callback);
|
| - void SetLostContextCallback(const base::Closure& callback);
|
|
|
| void GetProgramInfoCHROMIUMHelper(GLuint program,
|
| std::vector<int8_t>* result);
|
| @@ -264,6 +264,11 @@
|
| bool OnMemoryDump(const base::trace_event::MemoryDumpArgs& args,
|
| base::trace_event::ProcessMemoryDump* pmd) override;
|
|
|
| + void SetErrorMessageCallback(
|
| + GLES2ImplementationErrorMessageCallback* callback) {
|
| + error_message_callback_ = callback;
|
| + }
|
| +
|
| ShareGroup* share_group() const {
|
| return share_group_.get();
|
| }
|
| @@ -412,10 +417,6 @@
|
| T GetResultAs() {
|
| return static_cast<T>(GetResultBuffer());
|
| }
|
| -
|
| - // GpuControlClient implementation.
|
| - void OnGpuControlLostContext() final;
|
| - void OnGpuControlErrorMessage(const char* message, int32_t id) final;
|
|
|
| void* GetResultBuffer();
|
| int32_t GetResultShmId();
|
| @@ -824,11 +825,7 @@
|
|
|
| scoped_ptr<BufferTracker> buffer_tracker_;
|
|
|
| - base::Callback<void(const char*, int32_t)> error_message_callback_;
|
| - base::Closure lost_context_callback_;
|
| -#if DCHECK_IS_ON()
|
| - bool lost_context_ = false;
|
| -#endif
|
| + GLES2ImplementationErrorMessageCallback* error_message_callback_;
|
|
|
| int current_trace_stack_;
|
|
|
|
|