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

Side by Side Diff: webrtc/media/engine/webrtcvideocapturer.cc

Issue 1733673002: Removed unused cricket::VideoCapturer methods (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixed thread checker for android. SetCaptureFormat is called on the thread where the capturer is cr… Created 4 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 VideoCapturer::OnSinkWantsChanged(wants); 255 VideoCapturer::OnSinkWantsChanged(wants);
256 bool result = module_->SetApplyRotation(wants.rotation_applied); 256 bool result = module_->SetApplyRotation(wants.rotation_applied);
257 RTC_CHECK(result); 257 RTC_CHECK(result);
258 258
259 return; 259 return;
260 } 260 }
261 261
262 CaptureState WebRtcVideoCapturer::Start(const VideoFormat& capture_format) { 262 CaptureState WebRtcVideoCapturer::Start(const VideoFormat& capture_format) {
263 if (!module_) { 263 if (!module_) {
264 LOG(LS_ERROR) << "The capturer has not been initialized"; 264 LOG(LS_ERROR) << "The capturer has not been initialized";
265 return CS_NO_DEVICE; 265 return CS_FAILED;
266 } 266 }
267 if (start_thread_) { 267 if (start_thread_) {
268 LOG(LS_ERROR) << "The capturer is already running"; 268 LOG(LS_ERROR) << "The capturer is already running";
269 RTC_DCHECK(start_thread_->IsCurrent()) 269 RTC_DCHECK(start_thread_->IsCurrent())
270 << "Trying to start capturer on different threads"; 270 << "Trying to start capturer on different threads";
271 return CS_FAILED; 271 return CS_FAILED;
272 } 272 }
273 273
274 start_thread_ = rtc::Thread::Current(); 274 start_thread_ = rtc::Thread::Current();
275 RTC_DCHECK(!async_invoker_); 275 RTC_DCHECK(!async_invoker_);
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
417 pixel_width = 1; 417 pixel_width = 1;
418 pixel_height = 1; 418 pixel_height = 1;
419 // Convert units from VideoFrame RenderTimeMs to CapturedFrame (nanoseconds). 419 // Convert units from VideoFrame RenderTimeMs to CapturedFrame (nanoseconds).
420 time_stamp = sample.render_time_ms() * rtc::kNumNanosecsPerMillisec; 420 time_stamp = sample.render_time_ms() * rtc::kNumNanosecsPerMillisec;
421 data_size = rtc::checked_cast<uint32_t>(length); 421 data_size = rtc::checked_cast<uint32_t>(length);
422 data = buffer; 422 data = buffer;
423 rotation = sample.rotation(); 423 rotation = sample.rotation();
424 } 424 }
425 425
426 } // namespace cricket 426 } // namespace cricket
OLDNEW
« no previous file with comments | « webrtc/media/base/videocapturer_unittest.cc ('k') | webrtc/media/engine/webrtcvideocapturer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698