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

Side by Side Diff: content/renderer/media/media_stream_video_source.cc

Issue 416553002: VideoCaptureFormat: add method to print out pixel format as string (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 5 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 | « AUTHORS ('k') | media/video/capture/video_capture_types.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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "content/renderer/media/media_stream_video_source.h" 5 #include "content/renderer/media/media_stream_video_source.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <string> 9 #include <string>
10 10
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 // This object can be deleted after calling FinalizeAddTrack. See comment 463 // This object can be deleted after calling FinalizeAddTrack. See comment
464 // in the header file. 464 // in the header file.
465 FinalizeAddTrack(); 465 FinalizeAddTrack();
466 return; 466 return;
467 } 467 }
468 468
469 state_ = STARTING; 469 state_ = STARTING;
470 DVLOG(3) << "Starting the capturer with" 470 DVLOG(3) << "Starting the capturer with"
471 << " width = " << current_format_.frame_size.width() 471 << " width = " << current_format_.frame_size.width()
472 << " height = " << current_format_.frame_size.height() 472 << " height = " << current_format_.frame_size.height()
473 << " frame rate = " << current_format_.frame_rate; 473 << " frame rate = " << current_format_.frame_rate
474 << " pixel format = "
475 << media::VideoCaptureFormat::PixelFormatToString(
476 current_format_.pixel_format);
474 477
475 media::VideoCaptureParams params; 478 media::VideoCaptureParams params;
476 params.requested_format = current_format_; 479 params.requested_format = current_format_;
477 StartSourceImpl( 480 StartSourceImpl(
478 params, 481 params,
479 base::Bind(&VideoTrackAdapter::DeliverFrameOnIO, track_adapter_)); 482 base::Bind(&VideoTrackAdapter::DeliverFrameOnIO, track_adapter_));
480 } 483 }
481 484
482 bool MediaStreamVideoSource::FindBestFormatWithConstraints( 485 bool MediaStreamVideoSource::FindBestFormatWithConstraints(
483 const media::VideoCaptureFormats& formats, 486 const media::VideoCaptureFormats& formats,
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
607 : track(track), 610 : track(track),
608 frame_callback(frame_callback), 611 frame_callback(frame_callback),
609 constraints(constraints), 612 constraints(constraints),
610 callback(callback) { 613 callback(callback) {
611 } 614 }
612 615
613 MediaStreamVideoSource::RequestedConstraints::~RequestedConstraints() { 616 MediaStreamVideoSource::RequestedConstraints::~RequestedConstraints() {
614 } 617 }
615 618
616 } // namespace content 619 } // namespace content
OLDNEW
« no previous file with comments | « AUTHORS ('k') | media/video/capture/video_capture_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698