Chromium Code Reviews| 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 "content/common/gpu/client/gpu_channel_host.h" | 5 #include "content/common/gpu/client/gpu_channel_host.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| (...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 297 | 297 |
| 298 gfx::GpuMemoryBufferHandle GpuChannelHost::ShareGpuMemoryBufferToGpuProcess( | 298 gfx::GpuMemoryBufferHandle GpuChannelHost::ShareGpuMemoryBufferToGpuProcess( |
| 299 gfx::GpuMemoryBufferHandle source_handle) { | 299 gfx::GpuMemoryBufferHandle source_handle) { |
| 300 switch (source_handle.type) { | 300 switch (source_handle.type) { |
| 301 case gfx::SHARED_MEMORY_BUFFER: { | 301 case gfx::SHARED_MEMORY_BUFFER: { |
| 302 gfx::GpuMemoryBufferHandle handle; | 302 gfx::GpuMemoryBufferHandle handle; |
| 303 handle.type = gfx::SHARED_MEMORY_BUFFER; | 303 handle.type = gfx::SHARED_MEMORY_BUFFER; |
| 304 handle.handle = ShareToGpuProcess(source_handle.handle); | 304 handle.handle = ShareToGpuProcess(source_handle.handle); |
| 305 return handle; | 305 return handle; |
| 306 } | 306 } |
| 307 case gfx::OZONE_NATIVE_BUFFER: | |
|
reveman
2014/08/11 19:43:05
ifdef OZONE missing?
achaulk
2014/08/12 19:03:56
Done.
| |
| 308 return source_handle; | |
| 307 #if defined(OS_MACOSX) | 309 #if defined(OS_MACOSX) |
| 308 case gfx::IO_SURFACE_BUFFER: | 310 case gfx::IO_SURFACE_BUFFER: |
| 309 return source_handle; | 311 return source_handle; |
| 310 #endif | 312 #endif |
| 311 #if defined(OS_ANDROID) | 313 #if defined(OS_ANDROID) |
| 312 case gfx::SURFACE_TEXTURE_BUFFER: | 314 case gfx::SURFACE_TEXTURE_BUFFER: |
| 313 return source_handle; | 315 return source_handle; |
| 314 #endif | 316 #endif |
| 315 #if defined(USE_X11) | 317 #if defined(USE_X11) |
| 316 case gfx::X11_PIXMAP_BUFFER: | 318 case gfx::X11_PIXMAP_BUFFER: |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 402 | 404 |
| 403 listeners_.clear(); | 405 listeners_.clear(); |
| 404 } | 406 } |
| 405 | 407 |
| 406 bool GpuChannelHost::MessageFilter::IsLost() const { | 408 bool GpuChannelHost::MessageFilter::IsLost() const { |
| 407 AutoLock lock(lock_); | 409 AutoLock lock(lock_); |
| 408 return lost_; | 410 return lost_; |
| 409 } | 411 } |
| 410 | 412 |
| 411 } // namespace content | 413 } // namespace content |
| OLD | NEW |