Chromium Code Reviews| Index: gpu/command_buffer/tests/gl_manager.cc |
| diff --git a/gpu/command_buffer/tests/gl_manager.cc b/gpu/command_buffer/tests/gl_manager.cc |
| index c4b84a2c9df0a763ac853afab08ecbf63c2824d2..e910645561becbf9bf2595a6ce7a3792b6634d80 100644 |
| --- a/gpu/command_buffer/tests/gl_manager.cc |
| +++ b/gpu/command_buffer/tests/gl_manager.cc |
| @@ -16,6 +16,7 @@ |
| #include "gpu/command_buffer/service/context_group.h" |
| #include "gpu/command_buffer/service/gl_context_virtual.h" |
| #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
| +#include "gpu/command_buffer/service/gpu_control_service.h" |
| #include "gpu/command_buffer/service/gpu_scheduler.h" |
| #include "gpu/command_buffer/service/image_manager.h" |
| #include "gpu/command_buffer/service/mailbox_manager.h" |
| @@ -38,8 +39,7 @@ GLManager::Options::Options() |
| virtual_manager(NULL), |
| bind_generates_resource(false), |
| context_lost_allowed(false), |
| - image_manager(NULL), |
| - image_factory(NULL) { |
| + image_manager(NULL) { |
| } |
| GLManager::GLManager() |
| @@ -101,12 +101,24 @@ void GLManager::Initialize(const GLManager::Options& options) { |
| } |
| // From <EGL/egl.h>. |
| +#ifndef EGL_ALPHA_SIZE |
|
piman
2013/08/14 20:43:26
Why is this needed suddenly?
reveman
2013/08/15 15:00:54
this file now has to include gpu_control_service.h
|
| const int32 EGL_ALPHA_SIZE = 0x3021; |
| +#endif |
| +#ifndef EGL_BLUE_SIZE |
| const int32 EGL_BLUE_SIZE = 0x3022; |
| +#endif |
| +#ifndef EGL_GREEN_SIZE |
| const int32 EGL_GREEN_SIZE = 0x3023; |
| +#endif |
| +#ifndef EGL_RED_SIZE |
| const int32 EGL_RED_SIZE = 0x3024; |
| +#endif |
| +#ifndef EGL_DEPTH_SIZE |
| const int32 EGL_DEPTH_SIZE = 0x3025; |
| +#endif |
| +#ifndef EGL_NONE |
| const int32 EGL_NONE = 0x3038; |
| +#endif |
| mailbox_manager_ = |
| mailbox_manager ? mailbox_manager : new gles2::MailboxManager; |
| @@ -143,6 +155,10 @@ void GLManager::Initialize(const GLManager::Options& options) { |
| ASSERT_TRUE(command_buffer_->Initialize()) |
| << "could not create command buffer service"; |
| + gpu_control_.reset( |
| + new GpuControlService(decoder_->GetContextGroup()->image_manager(), |
| + options.gpu_memory_buffer_factory)); |
| + |
| gpu_scheduler_.reset(new GpuScheduler(command_buffer_.get(), |
| decoder_.get(), |
| decoder_.get())); |
| @@ -200,7 +216,7 @@ void GLManager::Initialize(const GLManager::Options& options) { |
| client_share_group, |
| transfer_buffer_.get(), |
| options.bind_generates_resource, |
| - options.image_factory)); |
| + gpu_control_.get())); |
| ASSERT_TRUE(gles2_implementation_->Initialize( |
| kStartTransferBufferSize, |