| OLD | NEW |
| 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 21 matching lines...) Expand all Loading... |
| 32 WebRtcVideoTrackAdapter(const blink::WebMediaStreamTrack& track, | 32 WebRtcVideoTrackAdapter(const blink::WebMediaStreamTrack& track, |
| 33 PeerConnectionDependencyFactory* factory); | 33 PeerConnectionDependencyFactory* factory); |
| 34 virtual ~WebRtcVideoTrackAdapter(); | 34 virtual ~WebRtcVideoTrackAdapter(); |
| 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 virtual 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_ |
| OLD | NEW |