| 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 "base/memory/shared_memory.h" | 5 #include "base/memory/shared_memory.h" |
| 6 #include "content/common/content_export.h" | 6 #include "content/common/content_export.h" |
| 7 #include "content/common/media/video_capture.h" | 7 #include "content/common/media/video_capture.h" |
| 8 #include "content/public/common/common_param_traits.h" | 8 #include "content/public/common/common_param_traits.h" |
| 9 #include "ipc/ipc_message_macros.h" | 9 #include "ipc/ipc_message_macros.h" |
| 10 #include "media/base/video_capture_types.h" | 10 #include "media/base/video_capture_types.h" |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 int /* device id */, | 40 int /* device id */, |
| 41 content::VideoCaptureState /* new state */) | 41 content::VideoCaptureState /* new state */) |
| 42 | 42 |
| 43 // Tell the renderer process that a new buffer is allocated for video capture. | 43 // Tell the renderer process that a new buffer is allocated for video capture. |
| 44 IPC_MESSAGE_CONTROL4(VideoCaptureMsg_NewBuffer, | 44 IPC_MESSAGE_CONTROL4(VideoCaptureMsg_NewBuffer, |
| 45 int /* device id */, | 45 int /* device id */, |
| 46 base::SharedMemoryHandle /* handle */, | 46 base::SharedMemoryHandle /* handle */, |
| 47 int /* length */, | 47 int /* length */, |
| 48 int /* buffer_id */) | 48 int /* buffer_id */) |
| 49 | 49 |
| 50 // Tell the renderer process that a new GpuMemoryBuffer backed buffer is | |
| 51 // allocated for video capture. | |
| 52 IPC_MESSAGE_CONTROL4(VideoCaptureMsg_NewBuffer2, | |
| 53 int /* device id */, | |
| 54 std::vector<gfx::GpuMemoryBufferHandle> /* handles */, | |
| 55 gfx::Size /* dimensions */, | |
| 56 int /* buffer_id */) | |
| 57 | |
| 58 // Tell the renderer process that it should release a buffer previously | 50 // Tell the renderer process that it should release a buffer previously |
| 59 // allocated by VideoCaptureMsg_NewBuffer. | 51 // allocated by VideoCaptureMsg_NewBuffer. |
| 60 IPC_MESSAGE_CONTROL2(VideoCaptureMsg_FreeBuffer, | 52 IPC_MESSAGE_CONTROL2(VideoCaptureMsg_FreeBuffer, |
| 61 int /* device id */, | 53 int /* device id */, |
| 62 int /* buffer_id */) | 54 int /* buffer_id */) |
| 63 | 55 |
| 64 // Tell the renderer process that a Buffer is available from video capture, and | 56 // Tell the renderer process that a Buffer is available from video capture, and |
| 65 // send the associated VideoFrame constituent parts as IPC parameters. | 57 // send the associated VideoFrame constituent parts as IPC parameters. |
| 66 IPC_MESSAGE_CONTROL1(VideoCaptureMsg_BufferReady, | 58 IPC_MESSAGE_CONTROL1(VideoCaptureMsg_BufferReady, |
| 67 VideoCaptureMsg_BufferReady_Params) | 59 VideoCaptureMsg_BufferReady_Params) |
| 68 | 60 |
| 69 // Tell the browser process that the renderer has finished reading from | 61 // Tell the browser process that the renderer has finished reading from |
| 70 // a buffer previously delivered by VideoCaptureMsg_BufferReady. | 62 // a buffer previously delivered by VideoCaptureMsg_BufferReady. |
| 71 IPC_MESSAGE_CONTROL4(VideoCaptureHostMsg_BufferReady, | 63 IPC_MESSAGE_CONTROL4(VideoCaptureHostMsg_BufferReady, |
| 72 int /* device_id */, | 64 int /* device_id */, |
| 73 int /* buffer_id */, | 65 int /* buffer_id */, |
| 74 gpu::SyncToken /* sync_token */, | 66 gpu::SyncToken /* sync_token */, |
| 75 double /* consumer_resource_utilization */) | 67 double /* consumer_resource_utilization */) |
| OLD | NEW |