| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "ppapi/proxy/ppb_context_3d_proxy.h" | 5 #include "ppapi/proxy/ppb_context_3d_proxy.h" |
| 6 | 6 |
| 7 #include "base/hash_tables.h" | 7 #include "base/hash_tables.h" |
| 8 #include "gpu/command_buffer/client/gles2_cmd_helper.h" | 8 #include "gpu/command_buffer/client/gles2_cmd_helper.h" |
| 9 #include "gpu/command_buffer/client/gles2_implementation.h" | 9 #include "gpu/command_buffer/client/gles2_implementation.h" |
| 10 #include "ppapi/c/pp_errors.h" | 10 #include "ppapi/c/pp_errors.h" |
| (...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 376 gpu::Buffer transfer_buffer = | 376 gpu::Buffer transfer_buffer = |
| 377 command_buffer_->GetTransferBuffer(transfer_buffer_id_); | 377 command_buffer_->GetTransferBuffer(transfer_buffer_id_); |
| 378 if (!transfer_buffer.ptr) | 378 if (!transfer_buffer.ptr) |
| 379 return false; | 379 return false; |
| 380 | 380 |
| 381 gles2_impl_.reset(new gpu::gles2::GLES2Implementation( | 381 gles2_impl_.reset(new gpu::gles2::GLES2Implementation( |
| 382 helper_.get(), | 382 helper_.get(), |
| 383 transfer_buffer.size, | 383 transfer_buffer.size, |
| 384 transfer_buffer.ptr, | 384 transfer_buffer.ptr, |
| 385 transfer_buffer_id_, | 385 transfer_buffer_id_, |
| 386 false, | 386 false)); |
| 387 true)); | |
| 388 | 387 |
| 389 return true; | 388 return true; |
| 390 } | 389 } |
| 391 | 390 |
| 392 int32_t Context3D::GetAttrib(int32_t attribute, int32_t* value) { | 391 int32_t Context3D::GetAttrib(int32_t attribute, int32_t* value) { |
| 393 // TODO(alokp): Implement me. | 392 // TODO(alokp): Implement me. |
| 394 return 0; | 393 return 0; |
| 395 } | 394 } |
| 396 | 395 |
| 397 int32_t Context3D::BindSurfaces(PP_Resource pp_draw, PP_Resource pp_read) { | 396 int32_t Context3D::BindSurfaces(PP_Resource pp_draw, PP_Resource pp_read) { |
| (...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 720 uint32_t shm_size = 0; | 719 uint32_t shm_size = 0; |
| 721 if (enter.succeeded() && | 720 if (enter.succeeded() && |
| 722 enter.object()->GetTransferBuffer(id, &shm_handle, &shm_size)) { | 721 enter.object()->GetTransferBuffer(id, &shm_handle, &shm_size)) { |
| 723 *transfer_buffer = TransportSHMHandleFromInt(dispatcher(), shm_handle); | 722 *transfer_buffer = TransportSHMHandleFromInt(dispatcher(), shm_handle); |
| 724 *size = shm_size; | 723 *size = shm_size; |
| 725 } | 724 } |
| 726 } | 725 } |
| 727 | 726 |
| 728 } // namespace proxy | 727 } // namespace proxy |
| 729 } // namespace pp | 728 } // namespace pp |
| OLD | NEW |