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

Side by Side Diff: content/renderer/media/webrtc/video_destination_handler.cc

Issue 287313002: Pass a TimeTicks along video capture pipeline to represent capture time (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merged and land Created 6 years, 6 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 | Annotate | Revision Log
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/webrtc/video_destination_handler.h" 5 #include "content/renderer/media/webrtc/video_destination_handler.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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 io_message_loop_->PostTask( 60 io_message_loop_->PostTask(
61 FROM_HERE, 61 FROM_HERE,
62 base::Bind(&FrameWriterDelegate::DeliverFrameOnIO, 62 base::Bind(&FrameWriterDelegate::DeliverFrameOnIO,
63 this, frame, format)); 63 this, frame, format));
64 } 64 }
65 65
66 void PpFrameWriter::FrameWriterDelegate::DeliverFrameOnIO( 66 void PpFrameWriter::FrameWriterDelegate::DeliverFrameOnIO(
67 const scoped_refptr<media::VideoFrame>& frame, 67 const scoped_refptr<media::VideoFrame>& frame,
68 const media::VideoCaptureFormat& format) { 68 const media::VideoCaptureFormat& format) {
69 DCHECK(io_message_loop_->BelongsToCurrentThread()); 69 DCHECK(io_message_loop_->BelongsToCurrentThread());
70 new_frame_callback_.Run(frame, format); 70 // The local time when this frame is generated is unknown so give a null
71 // value to |estimated_capture_time|.
72 new_frame_callback_.Run(frame, format, base::TimeTicks());
71 } 73 }
72 74
73 PpFrameWriter::PpFrameWriter() { 75 PpFrameWriter::PpFrameWriter() {
74 DVLOG(3) << "PpFrameWriter ctor"; 76 DVLOG(3) << "PpFrameWriter ctor";
75 } 77 }
76 78
77 PpFrameWriter::~PpFrameWriter() { 79 PpFrameWriter::~PpFrameWriter() {
78 DVLOG(3) << "PpFrameWriter dtor"; 80 DVLOG(3) << "PpFrameWriter dtor";
79 } 81 }
80 82
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 226
225 stream.addTrack(MediaStreamVideoTrack::CreateVideoTrack( 227 stream.addTrack(MediaStreamVideoTrack::CreateVideoTrack(
226 writer, constraints, MediaStreamVideoSource::ConstraintsCallback(), 228 writer, constraints, MediaStreamVideoSource::ConstraintsCallback(),
227 track_enabled)); 229 track_enabled));
228 230
229 *frame_writer = new PpFrameWriterProxy(writer->AsWeakPtr()); 231 *frame_writer = new PpFrameWriterProxy(writer->AsWeakPtr());
230 return true; 232 return true;
231 } 233 }
232 234
233 } // namespace content 235 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698