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

Unified Diff: content/renderer/media/rtc_video_capturer.cc

Issue 23551011: From Video Capture, abolish OnFrameInfo and enable resolution changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix constant declaration issue. Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/media/rtc_video_capturer.cc
diff --git a/content/renderer/media/rtc_video_capturer.cc b/content/renderer/media/rtc_video_capturer.cc
index fec4d091e8769438a47bc9840aa8c38ab141a140..45452a605b5da9beef3efe51936f4ccafe3e13ee 100644
--- a/content/renderer/media/rtc_video_capturer.cc
+++ b/content/renderer/media/rtc_video_capturer.cc
@@ -29,24 +29,23 @@ cricket::CaptureState RtcVideoCapturer::Start(
return cricket::CS_FAILED;
}
- media::VideoCaptureCapability cap;
- cap.width = capture_format.width;
- cap.height = capture_format.height;
- cap.frame_rate = capture_format.framerate();
- cap.color = media::PIXEL_FORMAT_I420;
+ media::VideoCaptureParams request;
+ request.width = capture_format.width;
+ request.height = capture_format.height;
+ request.frame_rate = capture_format.framerate();
SetCaptureFormat(&capture_format);
state_ = VIDEO_CAPTURE_STATE_STARTED;
first_frame_timestamp_ = media::kNoTimestamp();
delegate_->StartCapture(
- cap,
+ request,
base::Bind(&RtcVideoCapturer::OnFrameCaptured, base::Unretained(this)),
base::Bind(&RtcVideoCapturer::OnStateChange, base::Unretained(this)));
// Update the desired aspect ratio so that later the video frame can be
// cropped to meet the requirement if the camera returns a different
- // resolution than the |cap|.
- UpdateAspectRatio(cap.width, cap.height);
+ // resolution than the |request|.
+ UpdateAspectRatio(request.width, request.height);
return cricket::CS_STARTING;
}

Powered by Google App Engine
This is Rietveld 408576698