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

Side by Side Diff: content/renderer/media/webrtc/webrtc_video_track_adapter.h

Issue 670683003: Standardize usage of virtual/override/final in content/renderer/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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_WEBRTC_WEBRTC_VIDEO_TRACK_ADAPTER_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_VIDEO_TRACK_ADAPTER_H_
6 #define CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_VIDEO_TRACK_ADAPTER_H_ 6 #define CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_VIDEO_TRACK_ADAPTER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/threading/thread_checker.h" 9 #include "base/threading/thread_checker.h"
10 #include "content/public/renderer/media_stream_video_sink.h" 10 #include "content/public/renderer/media_stream_video_sink.h"
(...skipping 13 matching lines...) Expand all
24 // The responsibility of the class is to create and own a representation of a 24 // The responsibility of the class is to create and own a representation of a
25 // webrtc VideoTrack that can be added and removed from a RTCPeerConnection. 25 // webrtc VideoTrack that can be added and removed from a RTCPeerConnection.
26 // An instance of WebRtcVideoTrackAdapter is created when a VideoTrack is 26 // An instance of WebRtcVideoTrackAdapter is created when a VideoTrack is
27 // added to an RTCPeerConnection object. 27 // added to an RTCPeerConnection object.
28 // Instances of this class is owned by the WebRtcMediaStreamAdapter object that 28 // Instances of this class is owned by the WebRtcMediaStreamAdapter object that
29 // created it. 29 // created it.
30 class WebRtcVideoTrackAdapter : public MediaStreamVideoSink { 30 class WebRtcVideoTrackAdapter : public MediaStreamVideoSink {
31 public: 31 public:
32 WebRtcVideoTrackAdapter(const blink::WebMediaStreamTrack& track, 32 WebRtcVideoTrackAdapter(const blink::WebMediaStreamTrack& track,
33 PeerConnectionDependencyFactory* factory); 33 PeerConnectionDependencyFactory* factory);
34 virtual ~WebRtcVideoTrackAdapter(); 34 ~WebRtcVideoTrackAdapter() override;
35 35
36 webrtc::VideoTrackInterface* webrtc_video_track() { 36 webrtc::VideoTrackInterface* webrtc_video_track() {
37 return video_track_.get(); 37 return video_track_.get();
38 } 38 }
39 39
40 protected: 40 protected:
41 // Implementation of MediaStreamSink. 41 // Implementation of MediaStreamSink.
42 virtual void OnEnabledChanged(bool enabled) override; 42 void OnEnabledChanged(bool enabled) override;
43 43
44 private: 44 private:
45 // Used to DCHECK that we are called on the correct thread. 45 // Used to DCHECK that we are called on the correct thread.
46 base::ThreadChecker thread_checker_; 46 base::ThreadChecker thread_checker_;
47 47
48 scoped_refptr<webrtc::VideoTrackInterface> video_track_; 48 scoped_refptr<webrtc::VideoTrackInterface> video_track_;
49 blink::WebMediaStreamTrack web_track_; 49 blink::WebMediaStreamTrack web_track_;
50 50
51 class WebRtcVideoSourceAdapter; 51 class WebRtcVideoSourceAdapter;
52 scoped_refptr<WebRtcVideoSourceAdapter> source_adapter_; 52 scoped_refptr<WebRtcVideoSourceAdapter> source_adapter_;
53 53
54 DISALLOW_COPY_AND_ASSIGN(WebRtcVideoTrackAdapter); 54 DISALLOW_COPY_AND_ASSIGN(WebRtcVideoTrackAdapter);
55 }; 55 };
56 56
57 } // namespace content 57 } // namespace content
58 58
59 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_VIDEO_TRACK_ADAPTER_H_ 59 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_VIDEO_TRACK_ADAPTER_H_
OLDNEW
« no previous file with comments | « content/renderer/media/webrtc/webrtc_video_capturer_adapter.h ('k') | content/renderer/media/webrtc_audio_capturer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698