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

Side by Side Diff: content/renderer/media/video_track_adapter.h

Issue 1315993003: Reland: Change VideoCaptureDeliverFrameCB's signature (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address new changes Created 5 years, 4 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 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 #ifndef CONTENT_RENDERER_MEDIA_VIDEO_TRACK_ADAPTER_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_VIDEO_TRACK_ADAPTER_H_
6 #define CONTENT_RENDERER_MEDIA_VIDEO_TRACK_ADAPTER_H_ 6 #define CONTENT_RENDERER_MEDIA_VIDEO_TRACK_ADAPTER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 30 matching lines...) Expand all
41 void AddTrack(const MediaStreamVideoTrack* track, 41 void AddTrack(const MediaStreamVideoTrack* track,
42 VideoCaptureDeliverFrameCB frame_callback, 42 VideoCaptureDeliverFrameCB frame_callback,
43 int max_width, int max_height, 43 int max_width, int max_height,
44 double min_aspect_ratio, 44 double min_aspect_ratio,
45 double max_aspect_ratio, 45 double max_aspect_ratio,
46 double max_frame_rate); 46 double max_frame_rate);
47 void RemoveTrack(const MediaStreamVideoTrack* track); 47 void RemoveTrack(const MediaStreamVideoTrack* track);
48 48
49 // Delivers |frame| to all tracks that have registered a callback. 49 // Delivers |frame| to all tracks that have registered a callback.
50 // Must be called on the IO-thread. 50 // Must be called on the IO-thread.
51 void DeliverFrameOnIO( 51 void DeliverFrameOnIO(const scoped_refptr<media::VideoFrame>& frame,
52 const scoped_refptr<media::VideoFrame>& frame, 52 base::TimeTicks estimated_capture_time);
53 const base::TimeTicks& estimated_capture_time);
54 53
55 base::SingleThreadTaskRunner* io_task_runner() const { 54 base::SingleThreadTaskRunner* io_task_runner() const {
56 DCHECK(thread_checker_.CalledOnValidThread()); 55 DCHECK(thread_checker_.CalledOnValidThread());
57 return io_task_runner_.get(); 56 return io_task_runner_.get();
58 } 57 }
59 58
60 // Start monitor that frames are delivered to this object. I.E, that 59 // Start monitor that frames are delivered to this object. I.E, that
61 // |DeliverFrameOnIO| is called with a frame rate of |source_frame_rate|. 60 // |DeliverFrameOnIO| is called with a frame rate of |source_frame_rate|.
62 // |on_muted_callback| is triggered on the main render thread. 61 // |on_muted_callback| is triggered on the main render thread.
63 void StartFrameMonitoring(double source_frame_rate, 62 void StartFrameMonitoring(double source_frame_rate,
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 116
118 // Frame rate configured on the video source, accessed on the IO-thread. 117 // Frame rate configured on the video source, accessed on the IO-thread.
119 float source_frame_rate_; 118 float source_frame_rate_;
120 119
121 DISALLOW_COPY_AND_ASSIGN(VideoTrackAdapter); 120 DISALLOW_COPY_AND_ASSIGN(VideoTrackAdapter);
122 }; 121 };
123 122
124 } // namespace content 123 } // namespace content
125 124
126 #endif // CONTENT_RENDERER_MEDIA_VIDEO_TRACK_ADAPTER_H_ 125 #endif // CONTENT_RENDERER_MEDIA_VIDEO_TRACK_ADAPTER_H_
OLDNEW
« no previous file with comments | « content/renderer/media/video_source_handler.cc ('k') | content/renderer/media/video_track_adapter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698