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

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

Issue 2973503002: Remove unused parameters from MediaStreamVideoSource::StartCaptureImpl() (Closed)
Patch Set: rebase Created 3 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/pepper_to_video_track_adapter.h" 5 #include "content/renderer/media/pepper_to_video_track_adapter.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/base64.h" 9 #include "base/base64.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 29 matching lines...) Expand all
40 PpFrameWriter(); 40 PpFrameWriter();
41 ~PpFrameWriter() override; 41 ~PpFrameWriter() override;
42 42
43 // FrameWriterInterface implementation. 43 // FrameWriterInterface implementation.
44 // This method will be called by the Pepper host from render thread. 44 // This method will be called by the Pepper host from render thread.
45 void PutFrame(PPB_ImageData_Impl* image_data, int64_t time_stamp_ns) override; 45 void PutFrame(PPB_ImageData_Impl* image_data, int64_t time_stamp_ns) override;
46 46
47 protected: 47 protected:
48 // MediaStreamVideoSource implementation. 48 // MediaStreamVideoSource implementation.
49 void StartSourceImpl( 49 void StartSourceImpl(
50 const media::VideoCaptureFormat& format,
51 const blink::WebMediaConstraints& constraints,
52 const VideoCaptureDeliverFrameCB& frame_callback) override; 50 const VideoCaptureDeliverFrameCB& frame_callback) override;
53 void StopSourceImpl() override; 51 void StopSourceImpl() override;
54 52
55 private: 53 private:
56 media::VideoFramePool frame_pool_; 54 media::VideoFramePool frame_pool_;
57 55
58 class FrameWriterDelegate; 56 class FrameWriterDelegate;
59 scoped_refptr<FrameWriterDelegate> delegate_; 57 scoped_refptr<FrameWriterDelegate> delegate_;
60 58
61 DISALLOW_COPY_AND_ASSIGN(PpFrameWriter); 59 DISALLOW_COPY_AND_ASSIGN(PpFrameWriter);
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 103
106 PpFrameWriter::PpFrameWriter() { 104 PpFrameWriter::PpFrameWriter() {
107 DVLOG(3) << "PpFrameWriter ctor"; 105 DVLOG(3) << "PpFrameWriter ctor";
108 } 106 }
109 107
110 PpFrameWriter::~PpFrameWriter() { 108 PpFrameWriter::~PpFrameWriter() {
111 DVLOG(3) << "PpFrameWriter dtor"; 109 DVLOG(3) << "PpFrameWriter dtor";
112 } 110 }
113 111
114 void PpFrameWriter::StartSourceImpl( 112 void PpFrameWriter::StartSourceImpl(
115 const media::VideoCaptureFormat& format,
116 const blink::WebMediaConstraints& constraints,
117 const VideoCaptureDeliverFrameCB& frame_callback) { 113 const VideoCaptureDeliverFrameCB& frame_callback) {
118 DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); 114 DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
119 DCHECK(!delegate_.get()); 115 DCHECK(!delegate_.get());
120 DVLOG(3) << "PpFrameWriter::StartSourceImpl()"; 116 DVLOG(3) << "PpFrameWriter::StartSourceImpl()";
121 delegate_ = new FrameWriterDelegate(io_task_runner(), frame_callback); 117 delegate_ = new FrameWriterDelegate(io_task_runner(), frame_callback);
122 OnStartDone(MEDIA_DEVICE_OK); 118 OnStartDone(MEDIA_DEVICE_OK);
123 } 119 }
124 120
125 void PpFrameWriter::StopSourceImpl() { 121 void PpFrameWriter::StopSourceImpl() {
126 DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); 122 DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 242
247 bool track_enabled = true; 243 bool track_enabled = true;
248 stream.AddTrack(MediaStreamVideoTrack::CreateVideoTrack( 244 stream.AddTrack(MediaStreamVideoTrack::CreateVideoTrack(
249 writer, MediaStreamVideoSource::ConstraintsCallback(), track_enabled)); 245 writer, MediaStreamVideoSource::ConstraintsCallback(), track_enabled));
250 246
251 *frame_writer = new PpFrameWriterProxy(writer->AsWeakPtr()); 247 *frame_writer = new PpFrameWriterProxy(writer->AsWeakPtr());
252 return true; 248 return true;
253 } 249 }
254 250
255 } // namespace content 251 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698