| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "gpu/command_buffer/tests/gl_manager.h" | 5 #include "gpu/command_buffer/tests/gl_manager.h" |
| 6 | 6 |
| 7 #include <GLES2/gl2.h> | 7 #include <GLES2/gl2.h> |
| 8 #include <GLES2/gl2ext.h> | 8 #include <GLES2/gl2ext.h> |
| 9 #include <GLES2/gl2extchromium.h> | 9 #include <GLES2/gl2extchromium.h> |
| 10 | 10 |
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 decoder_->GetContextGroup()->transfer_buffer_manager())); | 225 decoder_->GetContextGroup()->transfer_buffer_manager())); |
| 226 ASSERT_TRUE(command_buffer_->Initialize()) | 226 ASSERT_TRUE(command_buffer_->Initialize()) |
| 227 << "could not create command buffer service"; | 227 << "could not create command buffer service"; |
| 228 | 228 |
| 229 gpu_scheduler_.reset(new GpuScheduler(command_buffer_.get(), | 229 gpu_scheduler_.reset(new GpuScheduler(command_buffer_.get(), |
| 230 decoder_.get(), | 230 decoder_.get(), |
| 231 decoder_.get())); | 231 decoder_.get())); |
| 232 | 232 |
| 233 decoder_->set_engine(gpu_scheduler_.get()); | 233 decoder_->set_engine(gpu_scheduler_.get()); |
| 234 | 234 |
| 235 surface_ = gfx::GLSurface::CreateOffscreenGLSurface(options.size); | 235 surface_ = gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size()); |
| 236 ASSERT_TRUE(surface_.get() != NULL) << "could not create offscreen surface"; | 236 ASSERT_TRUE(surface_.get() != NULL) << "could not create offscreen surface"; |
| 237 | 237 |
| 238 if (base_context_) { | 238 if (base_context_) { |
| 239 context_ = scoped_refptr<gfx::GLContext>(new gpu::GLContextVirtual( | 239 context_ = scoped_refptr<gfx::GLContext>(new gpu::GLContextVirtual( |
| 240 share_group_.get(), base_context_->get(), decoder_->AsWeakPtr())); | 240 share_group_.get(), base_context_->get(), decoder_->AsWeakPtr())); |
| 241 ASSERT_TRUE(context_->Initialize( | 241 ASSERT_TRUE(context_->Initialize( |
| 242 surface_.get(), gfx::PreferIntegratedGpu)); | 242 surface_.get(), gfx::PreferIntegratedGpu)); |
| 243 } else { | 243 } else { |
| 244 if (real_gl_context) { | 244 if (real_gl_context) { |
| 245 context_ = scoped_refptr<gfx::GLContext>(new gpu::GLContextVirtual( | 245 context_ = scoped_refptr<gfx::GLContext>(new gpu::GLContextVirtual( |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 435 uint32 GLManager::CreateStreamTexture(uint32 texture_id) { | 435 uint32 GLManager::CreateStreamTexture(uint32 texture_id) { |
| 436 NOTIMPLEMENTED(); | 436 NOTIMPLEMENTED(); |
| 437 return 0; | 437 return 0; |
| 438 } | 438 } |
| 439 | 439 |
| 440 void GLManager::SetLock(base::Lock*) { | 440 void GLManager::SetLock(base::Lock*) { |
| 441 NOTIMPLEMENTED(); | 441 NOTIMPLEMENTED(); |
| 442 } | 442 } |
| 443 | 443 |
| 444 } // namespace gpu | 444 } // namespace gpu |
| OLD | NEW |