Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(56)

Side by Side Diff: media/video/capture/android/video_capture_device_android.cc

Issue 292663010: Merge 271560 "Add a ChromeOS implementation of VideoCaptureDevic..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1985/src/
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « media/media.gyp ('k') | media/video/capture/fake_video_capture_device_factory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "media/video/capture/android/video_capture_device_android.h" 5 #include "media/video/capture/android/video_capture_device_android.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
10 #include "base/android/scoped_java_ref.h" 10 #include "base/android/scoped_java_ref.h"
(...skipping 17 matching lines...) Expand all
28 28
29 // static 29 // static
30 void VideoCaptureDevice::GetDeviceSupportedFormats( 30 void VideoCaptureDevice::GetDeviceSupportedFormats(
31 const Name& device, 31 const Name& device,
32 VideoCaptureFormats* capture_formats) { 32 VideoCaptureFormats* capture_formats) {
33 VideoCaptureDeviceFactoryAndroid::GetDeviceSupportedFormats(device, 33 VideoCaptureDeviceFactoryAndroid::GetDeviceSupportedFormats(device,
34 capture_formats); 34 capture_formats);
35 } 35 }
36 36
37 // static 37 // static
38 VideoCaptureDevice* VideoCaptureDevice::Create(const Name& device_name) { 38 VideoCaptureDevice* VideoCaptureDevice::Create(
39 scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner,
40 const Name& device_name) {
39 return VideoCaptureDeviceAndroid::Create(device_name); 41 return VideoCaptureDeviceAndroid::Create(device_name);
40 } 42 }
41 43
42 // static 44 // static
43 VideoCaptureDevice* VideoCaptureDeviceAndroid::Create(const Name& device_name) { 45 VideoCaptureDevice* VideoCaptureDeviceAndroid::Create(const Name& device_name) {
44 scoped_ptr<VideoCaptureDeviceAndroid> ret( 46 scoped_ptr<VideoCaptureDeviceAndroid> ret(
45 new VideoCaptureDeviceAndroid(device_name)); 47 new VideoCaptureDeviceAndroid(device_name));
46 if (ret->Init()) 48 if (ret->Init())
47 return ret.release(); 49 return ret.release();
48 return NULL; 50 return NULL;
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 void VideoCaptureDeviceAndroid::SetErrorState(const std::string& reason) { 221 void VideoCaptureDeviceAndroid::SetErrorState(const std::string& reason) {
220 LOG(ERROR) << "VideoCaptureDeviceAndroid::SetErrorState: " << reason; 222 LOG(ERROR) << "VideoCaptureDeviceAndroid::SetErrorState: " << reason;
221 { 223 {
222 base::AutoLock lock(lock_); 224 base::AutoLock lock(lock_);
223 state_ = kError; 225 state_ = kError;
224 } 226 }
225 client_->OnError(reason); 227 client_->OnError(reason);
226 } 228 }
227 229
228 } // namespace media 230 } // namespace media
OLDNEW
« no previous file with comments | « media/media.gyp ('k') | media/video/capture/fake_video_capture_device_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698