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

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

Issue 2011163004: MediaVideoStreamTrack should store weak reference to the media source. Since MediaVideoStreamSource… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2704
Patch Set: Created 4 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_TRACK_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_TRACK_H_
6 #define CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_TRACK_H_ 6 #define CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_TRACK_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 77
78 std::vector<MediaStreamVideoSink*> sinks_; 78 std::vector<MediaStreamVideoSink*> sinks_;
79 79
80 // |FrameDeliverer| is an internal helper object used for delivering video 80 // |FrameDeliverer| is an internal helper object used for delivering video
81 // frames on the IO-thread using callbacks to all registered tracks. 81 // frames on the IO-thread using callbacks to all registered tracks.
82 class FrameDeliverer; 82 class FrameDeliverer;
83 const scoped_refptr<FrameDeliverer> frame_deliverer_; 83 const scoped_refptr<FrameDeliverer> frame_deliverer_;
84 84
85 const blink::WebMediaConstraints constraints_; 85 const blink::WebMediaConstraints constraints_;
86 86
87 // Weak ref to the source this tracks is connected to. |source_| is owned 87 // Weak ref to the source this tracks is connected to.
88 // by the blink::WebMediaStreamSource and is guaranteed to outlive the 88 base::WeakPtr<MediaStreamVideoSource> source_;
89 // track.
90 MediaStreamVideoSource* source_;
91 89
92 DISALLOW_COPY_AND_ASSIGN(MediaStreamVideoTrack); 90 DISALLOW_COPY_AND_ASSIGN(MediaStreamVideoTrack);
93 }; 91 };
94 92
95 } // namespace content 93 } // namespace content
96 94
97 #endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_TRACK_H_ 95 #endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_VIDEO_TRACK_H_
OLDNEW
« no previous file with comments | « content/renderer/media/media_stream_video_source.h ('k') | content/renderer/media/media_stream_video_track.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698