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 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 attrib_helper.depth_size = 16; | 268 attrib_helper.depth_size = 16; |
269 attrib_helper.stencil_size = 8; | 269 attrib_helper.stencil_size = 8; |
270 attrib_helper.webgl_version = options.webgl_version; | 270 attrib_helper.webgl_version = options.webgl_version; |
271 attrib_helper.Serialize(&attribs); | 271 attrib_helper.Serialize(&attribs); |
272 | 272 |
273 DCHECK(!command_line || !context_group); | 273 DCHECK(!command_line || !context_group); |
274 if (!context_group) { | 274 if (!context_group) { |
275 scoped_refptr<gles2::FeatureInfo> feature_info; | 275 scoped_refptr<gles2::FeatureInfo> feature_info; |
276 if (command_line) | 276 if (command_line) |
277 feature_info = new gles2::FeatureInfo(*command_line); | 277 feature_info = new gles2::FeatureInfo(*command_line); |
278 context_group = | 278 context_group = new gles2::ContextGroup( |
279 new gles2::ContextGroup(mailbox_manager_.get(), | 279 mailbox_manager_.get(), NULL, new gpu::gles2::ShaderTranslatorCache, |
280 NULL, | 280 new gpu::gles2::FramebufferCompletenessCache, feature_info, NULL, NULL, |
281 new gpu::gles2::ShaderTranslatorCache, | 281 options.bind_generates_resource); |
282 feature_info, | |
283 NULL, | |
284 NULL, | |
285 options.bind_generates_resource); | |
286 } | 282 } |
287 | 283 |
288 decoder_.reset(::gpu::gles2::GLES2Decoder::Create(context_group)); | 284 decoder_.reset(::gpu::gles2::GLES2Decoder::Create(context_group)); |
289 | 285 |
290 command_buffer_.reset(new CommandBufferService( | 286 command_buffer_.reset(new CommandBufferService( |
291 decoder_->GetContextGroup()->transfer_buffer_manager())); | 287 decoder_->GetContextGroup()->transfer_buffer_manager())); |
292 ASSERT_TRUE(command_buffer_->Initialize()) | 288 ASSERT_TRUE(command_buffer_->Initialize()) |
293 << "could not create command buffer service"; | 289 << "could not create command buffer service"; |
294 | 290 |
295 gpu_scheduler_.reset(new GpuScheduler(command_buffer_.get(), | 291 gpu_scheduler_.reset(new GpuScheduler(command_buffer_.get(), |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
506 void GLManager::SetLock(base::Lock*) { | 502 void GLManager::SetLock(base::Lock*) { |
507 NOTIMPLEMENTED(); | 503 NOTIMPLEMENTED(); |
508 } | 504 } |
509 | 505 |
510 bool GLManager::IsGpuChannelLost() { | 506 bool GLManager::IsGpuChannelLost() { |
511 NOTIMPLEMENTED(); | 507 NOTIMPLEMENTED(); |
512 return false; | 508 return false; |
513 } | 509 } |
514 | 510 |
515 } // namespace gpu | 511 } // namespace gpu |
OLD | NEW |