| 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 "content/renderer/media/video_capture_module_impl.h" | 5 #include "content/renderer/media/video_capture_module_impl.h" |
| 6 | 6 |
| 7 #include "base/atomicops.h" | 7 #include "base/atomicops.h" |
| 8 #include "content/renderer/media/video_capture_impl_manager.h" | 8 #include "content/renderer/media/video_capture_impl_manager.h" |
| 9 | 9 |
| 10 VideoCaptureModuleImpl::VideoCaptureModuleImpl( | 10 VideoCaptureModuleImpl::VideoCaptureModuleImpl( |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 | 98 |
| 99 void VideoCaptureModuleImpl::OnPaused(media::VideoCapture* capture) { | 99 void VideoCaptureModuleImpl::OnPaused(media::VideoCapture* capture) { |
| 100 NOTIMPLEMENTED(); | 100 NOTIMPLEMENTED(); |
| 101 } | 101 } |
| 102 | 102 |
| 103 void VideoCaptureModuleImpl::OnError(media::VideoCapture* capture, | 103 void VideoCaptureModuleImpl::OnError(media::VideoCapture* capture, |
| 104 int error_code) { | 104 int error_code) { |
| 105 NOTIMPLEMENTED(); | 105 NOTIMPLEMENTED(); |
| 106 } | 106 } |
| 107 | 107 |
| 108 void VideoCaptureModuleImpl::OnRemoved(media::VideoCapture* capture) { |
| 109 NOTIMPLEMENTED(); |
| 110 } |
| 111 |
| 108 void VideoCaptureModuleImpl::OnBufferReady( | 112 void VideoCaptureModuleImpl::OnBufferReady( |
| 109 media::VideoCapture* capture, | 113 media::VideoCapture* capture, |
| 110 scoped_refptr<media::VideoCapture::VideoFrameBuffer> buf) { | 114 scoped_refptr<media::VideoCapture::VideoFrameBuffer> buf) { |
| 111 message_loop_proxy_->PostTask( | 115 message_loop_proxy_->PostTask( |
| 112 FROM_HERE, | 116 FROM_HERE, |
| 113 NewRunnableMethod(this, | 117 NewRunnableMethod(this, |
| 114 &VideoCaptureModuleImpl::OnBufferReadyOnCaptureThread, | 118 &VideoCaptureModuleImpl::OnBufferReadyOnCaptureThread, |
| 115 capture, buf)); | 119 capture, buf)); |
| 116 } | 120 } |
| 117 | 121 |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 218 | 222 |
| 219 IncomingFrame( | 223 IncomingFrame( |
| 220 static_cast<WebRtc_UWord8*>(buf->memory_pointer), | 224 static_cast<WebRtc_UWord8*>(buf->memory_pointer), |
| 221 static_cast<WebRtc_Word32>(buf->buffer_size), | 225 static_cast<WebRtc_Word32>(buf->buffer_size), |
| 222 frameInfo_, | 226 frameInfo_, |
| 223 static_cast<WebRtc_Word64>( | 227 static_cast<WebRtc_Word64>( |
| 224 (buf->timestamp - start_time_).InMicroseconds())); | 228 (buf->timestamp - start_time_).InMicroseconds())); |
| 225 | 229 |
| 226 capture->FeedBuffer(buf); | 230 capture->FeedBuffer(buf); |
| 227 } | 231 } |
| OLD | NEW |