Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(116)

Side by Side Diff: mojo/gles2/command_buffer_client_impl.cc

Issue 1320783002: Make SharedMemoryHandle a class on windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ipc_global
Patch Set: Rebase. Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ipc/ipc_message_utils.cc ('k') | ppapi/proxy/ppb_image_data_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "mojo/gles2/command_buffer_client_impl.h" 5 #include "mojo/gles2/command_buffer_client_impl.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/process/process_handle.h" 10 #include "base/process/process_handle.h"
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 size->height = static_cast<int32_t>(height); 265 size->height = static_cast<int32_t>(height);
266 266
267 mus::MojoGpuMemoryBufferImpl* gpu_memory_buffer = 267 mus::MojoGpuMemoryBufferImpl* gpu_memory_buffer =
268 mus::MojoGpuMemoryBufferImpl::FromClientBuffer(buffer); 268 mus::MojoGpuMemoryBufferImpl::FromClientBuffer(buffer);
269 gfx::GpuMemoryBufferHandle handle = gpu_memory_buffer->GetHandle(); 269 gfx::GpuMemoryBufferHandle handle = gpu_memory_buffer->GetHandle();
270 270
271 bool requires_sync_point = false; 271 bool requires_sync_point = false;
272 base::SharedMemoryHandle dupd_handle = 272 base::SharedMemoryHandle dupd_handle =
273 base::SharedMemory::DuplicateHandle(handle.handle); 273 base::SharedMemory::DuplicateHandle(handle.handle);
274 #if defined(OS_WIN) 274 #if defined(OS_WIN)
275 HANDLE platform_handle = dupd_handle; 275 HANDLE platform_handle = dupd_handle.GetHandle();
276 #else 276 #else
277 int platform_handle = dupd_handle.fd; 277 int platform_handle = dupd_handle.fd;
278 #endif 278 #endif
279 279
280 if (handle.type != gfx::SHARED_MEMORY_BUFFER) { 280 if (handle.type != gfx::SHARED_MEMORY_BUFFER) {
281 requires_sync_point = true; 281 requires_sync_point = true;
282 NOTIMPLEMENTED(); 282 NOTIMPLEMENTED();
283 return -1; 283 return -1;
284 } 284 }
285 285
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
402 402
403 uint64_t CommandBufferClientImpl::GetCommandBufferID() const { 403 uint64_t CommandBufferClientImpl::GetCommandBufferID() const {
404 // TODO (rjkroege): This must correspond to the command buffer ID on the 404 // TODO (rjkroege): This must correspond to the command buffer ID on the
405 // server side. Most likely a combination of the client-specific integer and 405 // server side. Most likely a combination of the client-specific integer and
406 // the connect id. 406 // the connect id.
407 NOTIMPLEMENTED(); 407 NOTIMPLEMENTED();
408 return 0; 408 return 0;
409 } 409 }
410 410
411 } // namespace gles2 411 } // namespace gles2
OLDNEW
« no previous file with comments | « ipc/ipc_message_utils.cc ('k') | ppapi/proxy/ppb_image_data_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698