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 // VideoCaptureHost serves video capture related messages from | 5 // VideoCaptureHost serves video capture related messages from |
6 // VideoCaptureMessageFilter which lives inside the render process. | 6 // VideoCaptureMessageFilter which lives inside the render process. |
7 // | 7 // |
8 // This class is owned by RenderProcessHostImpl, and instantiated on UI | 8 // This class is owned by RenderProcessHostImpl, and instantiated on UI |
9 // thread, but all other operations and method calls happen on IO thread. | 9 // thread, but all other operations and method calls happen on IO thread. |
10 // | 10 // |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 void OnChannelClosing() override; | 75 void OnChannelClosing() override; |
76 void OnDestruct() const override; | 76 void OnDestruct() const override; |
77 bool OnMessageReceived(const IPC::Message& message) override; | 77 bool OnMessageReceived(const IPC::Message& message) override; |
78 | 78 |
79 // VideoCaptureControllerEventHandler implementation. | 79 // VideoCaptureControllerEventHandler implementation. |
80 void OnError(VideoCaptureControllerID id) override; | 80 void OnError(VideoCaptureControllerID id) override; |
81 void OnBufferCreated(VideoCaptureControllerID id, | 81 void OnBufferCreated(VideoCaptureControllerID id, |
82 base::SharedMemoryHandle handle, | 82 base::SharedMemoryHandle handle, |
83 int length, | 83 int length, |
84 int buffer_id) override; | 84 int buffer_id) override; |
| 85 void OnBufferCreated2(VideoCaptureControllerID id, |
| 86 const std::vector<gfx::GpuMemoryBufferHandle>& handles, |
| 87 const gfx::Size& size, |
| 88 int buffer_id) override; |
85 void OnBufferDestroyed(VideoCaptureControllerID id, | 89 void OnBufferDestroyed(VideoCaptureControllerID id, |
86 int buffer_id) override; | 90 int buffer_id) override; |
87 void OnBufferReady(VideoCaptureControllerID id, | 91 void OnBufferReady(VideoCaptureControllerID id, |
88 int buffer_id, | 92 int buffer_id, |
89 const scoped_refptr<media::VideoFrame>& frame, | 93 const scoped_refptr<media::VideoFrame>& frame, |
90 const base::TimeTicks& timestamp) override; | 94 const base::TimeTicks& timestamp) override; |
91 void OnEnded(VideoCaptureControllerID id) override; | 95 void OnEnded(VideoCaptureControllerID id) override; |
92 | 96 |
93 private: | 97 private: |
94 friend class BrowserThread; | 98 friend class BrowserThread; |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 // is connected. An entry in this map holds a null controller while it is in | 159 // is connected. An entry in this map holds a null controller while it is in |
156 // the process of starting. | 160 // the process of starting. |
157 EntryMap entries_; | 161 EntryMap entries_; |
158 | 162 |
159 DISALLOW_COPY_AND_ASSIGN(VideoCaptureHost); | 163 DISALLOW_COPY_AND_ASSIGN(VideoCaptureHost); |
160 }; | 164 }; |
161 | 165 |
162 } // namespace content | 166 } // namespace content |
163 | 167 |
164 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_ | 168 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_HOST_H_ |
OLD | NEW |