| 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 // Unit test for VideoCaptureController. | 5 // Unit test for VideoCaptureController. |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 143 const scoped_refptr<media::VideoCaptureDevice::Client::Buffer>& buffer, | 143 const scoped_refptr<media::VideoCaptureDevice::Client::Buffer>& buffer, |
| 144 scoped_ptr<gpu::MailboxHolder> holder, | 144 scoped_ptr<gpu::MailboxHolder> holder, |
| 145 const media::VideoFrame::ReleaseMailboxCB& release_cb, | 145 const media::VideoFrame::ReleaseMailboxCB& release_cb, |
| 146 gfx::Size dimensions) { | 146 gfx::Size dimensions) { |
| 147 return media::VideoFrame::WrapNativeTexture( | 147 return media::VideoFrame::WrapNativeTexture( |
| 148 holder.Pass(), | 148 holder.Pass(), |
| 149 release_cb, | 149 release_cb, |
| 150 dimensions, | 150 dimensions, |
| 151 gfx::Rect(dimensions), | 151 gfx::Rect(dimensions), |
| 152 dimensions, | 152 dimensions, |
| 153 base::TimeDelta(), | 153 base::TimeDelta()); |
| 154 media::VideoFrame::ReadPixelsCB()); | |
| 155 } | 154 } |
| 156 | 155 |
| 157 TestBrowserThreadBundle bundle_; | 156 TestBrowserThreadBundle bundle_; |
| 158 scoped_ptr<MockVideoCaptureControllerEventHandler> client_a_; | 157 scoped_ptr<MockVideoCaptureControllerEventHandler> client_a_; |
| 159 scoped_ptr<MockVideoCaptureControllerEventHandler> client_b_; | 158 scoped_ptr<MockVideoCaptureControllerEventHandler> client_b_; |
| 160 scoped_ptr<VideoCaptureController> controller_; | 159 scoped_ptr<VideoCaptureController> controller_; |
| 161 scoped_ptr<media::VideoCaptureDevice::Client> device_; | 160 scoped_ptr<media::VideoCaptureDevice::Client> device_; |
| 162 | 161 |
| 163 private: | 162 private: |
| 164 DISALLOW_COPY_AND_ASSIGN(VideoCaptureControllerTest); | 163 DISALLOW_COPY_AND_ASSIGN(VideoCaptureControllerTest); |
| (...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 662 device_->OnIncomingCapturedData( | 661 device_->OnIncomingCapturedData( |
| 663 static_cast<unsigned char*>(buffer.get()->data()), | 662 static_cast<unsigned char*>(buffer.get()->data()), |
| 664 buffer.get()->size(), | 663 buffer.get()->size(), |
| 665 params.requested_format, | 664 params.requested_format, |
| 666 0, | 665 0, |
| 667 base::TimeTicks()); | 666 base::TimeTicks()); |
| 668 } | 667 } |
| 669 } | 668 } |
| 670 | 669 |
| 671 } // namespace content | 670 } // namespace content |
| OLD | NEW |