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

Unified Diff: content/renderer/pepper/pepper_video_capture_host.cc

Issue 23551011: From Video Capture, abolish OnFrameInfo and enable resolution changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add assert to vcbp unittest 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/pepper/pepper_video_capture_host.cc
diff --git a/content/renderer/pepper/pepper_video_capture_host.cc b/content/renderer/pepper/pepper_video_capture_host.cc
index cf06bcaf1d0539bc1545e4feba8450f4a5d8d9a2..42e59ee9e759cdef503d952823ee789f86efc00b 100644
--- a/content/renderer/pepper/pepper_video_capture_host.cc
+++ b/content/renderer/pepper/pepper_video_capture_host.cc
@@ -167,7 +167,7 @@ void PepperVideoCaptureHost::OnFrameReady(
void PepperVideoCaptureHost::OnDeviceInfoReceived(
media::VideoCapture* capture,
- const media::VideoCaptureParams& device_info) {
+ const media::VideoCaptureFormat& device_info) {
PP_VideoCaptureDeviceInfo_Dev info = {
static_cast<uint32_t>(device_info.width),
static_cast<uint32_t>(device_info.height),
@@ -292,7 +292,7 @@ int32_t PepperVideoCaptureHost::OnStartCapture(
// It's safe to call this regardless it's capturing or not, because
// PepperPlatformVideoCapture maintains the state.
- platform_video_capture_->StartCapture(this, capability_);
+ platform_video_capture_->StartCapture(this, param_request_);
return PP_OK;
}
@@ -358,12 +358,9 @@ void PepperVideoCaptureHost::SetRequestedInfo(
// Clamp the buffer count to between 1 and |kMaxBuffers|.
buffer_count_hint_ = std::min(std::max(buffer_count, 1U), kMaxBuffers);
- capability_.width = device_info.width;
- capability_.height = device_info.height;
- capability_.frame_rate = device_info.frames_per_second;
- capability_.expected_capture_delay = 0; // Ignored.
- capability_.color = media::PIXEL_FORMAT_I420;
- capability_.interlaced = false; // Ignored.
+ param_request_.width = device_info.width;
+ param_request_.height = device_info.height;
+ param_request_.frame_rate = device_info.frames_per_second;
}
void PepperVideoCaptureHost::DetachPlatformVideoCapture() {

Powered by Google App Engine
This is Rietveld 408576698