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

Side by Side Diff: webkit/plugins/ppapi/ppb_video_capture_impl.cc

Issue 10035054: Merge VideoCaptureDevice::Capability with media::VideoCaptureCapability (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix a namespace issue Created 8 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
« no previous file with comments | « media/video/capture/win/video_capture_device_win.cc ('k') | no next file » | 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) 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 #include "webkit/plugins/ppapi/ppb_video_capture_impl.h" 5 #include "webkit/plugins/ppapi/ppb_video_capture_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 void PPB_VideoCapture_Impl::SetRequestedInfo( 285 void PPB_VideoCapture_Impl::SetRequestedInfo(
286 const PP_VideoCaptureDeviceInfo_Dev& device_info, 286 const PP_VideoCaptureDeviceInfo_Dev& device_info,
287 uint32_t buffer_count) { 287 uint32_t buffer_count) {
288 // Clamp the buffer count to between 1 and |kMaxBuffers|. 288 // Clamp the buffer count to between 1 and |kMaxBuffers|.
289 buffer_count_hint_ = std::min(std::max(buffer_count, 1U), kMaxBuffers); 289 buffer_count_hint_ = std::min(std::max(buffer_count, 1U), kMaxBuffers);
290 290
291 capability_.width = device_info.width; 291 capability_.width = device_info.width;
292 capability_.height = device_info.height; 292 capability_.height = device_info.height;
293 capability_.frame_rate = device_info.frames_per_second; 293 capability_.frame_rate = device_info.frames_per_second;
294 capability_.expected_capture_delay = 0; // Ignored. 294 capability_.expected_capture_delay = 0; // Ignored.
295 capability_.color = media::VideoFrame::I420; 295 capability_.color = media::VideoCaptureCapability::kI420;
296 capability_.interlaced = false; // Ignored. 296 capability_.interlaced = false; // Ignored.
297 } 297 }
298 298
299 void PPB_VideoCapture_Impl::DetachPlatformVideoCapture() { 299 void PPB_VideoCapture_Impl::DetachPlatformVideoCapture() {
300 if (platform_video_capture_.get()) { 300 if (platform_video_capture_.get()) {
301 platform_video_capture_->DetachEventHandler(); 301 platform_video_capture_->DetachEventHandler();
302 platform_video_capture_ = NULL; 302 platform_video_capture_ = NULL;
303 } 303 }
304 } 304 }
305 305
(...skipping 12 matching lines...) Expand all
318 : in_use(false), 318 : in_use(false),
319 data(NULL), 319 data(NULL),
320 buffer() { 320 buffer() {
321 } 321 }
322 322
323 PPB_VideoCapture_Impl::BufferInfo::~BufferInfo() { 323 PPB_VideoCapture_Impl::BufferInfo::~BufferInfo() {
324 } 324 }
325 325
326 } // namespace ppapi 326 } // namespace ppapi
327 } // namespace webkit 327 } // namespace webkit
OLDNEW
« no previous file with comments | « media/video/capture/win/video_capture_device_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698