| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_REMOTE_MEDIA_STREAM_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_REMOTE_MEDIA_STREAM_IMPL_H_ |
| 6 #define CONTENT_RENDERER_MEDIA_REMOTE_MEDIA_STREAM_IMPL_H_ | 6 #define CONTENT_RENDERER_MEDIA_REMOTE_MEDIA_STREAM_IMPL_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 // RemoteMediaStreamImpl serves as a container and glue between remote webrtc | 23 // RemoteMediaStreamImpl serves as a container and glue between remote webrtc |
| 24 // MediaStreams and WebKit MediaStreams. For each remote MediaStream received | 24 // MediaStreams and WebKit MediaStreams. For each remote MediaStream received |
| 25 // on a PeerConnection a RemoteMediaStreamImpl instance is created and | 25 // on a PeerConnection a RemoteMediaStreamImpl instance is created and |
| 26 // owned by RtcPeerConnection. | 26 // owned by RtcPeerConnection. |
| 27 class CONTENT_EXPORT RemoteMediaStreamImpl | 27 class CONTENT_EXPORT RemoteMediaStreamImpl |
| 28 : NON_EXPORTED_BASE(public webrtc::ObserverInterface), | 28 : NON_EXPORTED_BASE(public webrtc::ObserverInterface), |
| 29 NON_EXPORTED_BASE(public base::NonThreadSafe) { | 29 NON_EXPORTED_BASE(public base::NonThreadSafe) { |
| 30 public: | 30 public: |
| 31 explicit RemoteMediaStreamImpl( | 31 explicit RemoteMediaStreamImpl( |
| 32 webrtc::MediaStreamInterface* webrtc_stream); | 32 webrtc::MediaStreamInterface* webrtc_stream); |
| 33 virtual ~RemoteMediaStreamImpl(); | 33 ~RemoteMediaStreamImpl() override; |
| 34 | 34 |
| 35 const blink::WebMediaStream& webkit_stream() { return webkit_stream_; } | 35 const blink::WebMediaStream& webkit_stream() { return webkit_stream_; } |
| 36 | 36 |
| 37 private: | 37 private: |
| 38 // webrtc::ObserverInterface implementation. | 38 // webrtc::ObserverInterface implementation. |
| 39 virtual void OnChanged() override; | 39 void OnChanged() override; |
| 40 | 40 |
| 41 scoped_refptr<webrtc::MediaStreamInterface> webrtc_stream_; | 41 scoped_refptr<webrtc::MediaStreamInterface> webrtc_stream_; |
| 42 ScopedVector<RemoteMediaStreamTrackAdapter> video_track_observers_; | 42 ScopedVector<RemoteMediaStreamTrackAdapter> video_track_observers_; |
| 43 ScopedVector<RemoteMediaStreamTrackAdapter> audio_track_observers_; | 43 ScopedVector<RemoteMediaStreamTrackAdapter> audio_track_observers_; |
| 44 blink::WebMediaStream webkit_stream_; | 44 blink::WebMediaStream webkit_stream_; |
| 45 | 45 |
| 46 DISALLOW_COPY_AND_ASSIGN(RemoteMediaStreamImpl); | 46 DISALLOW_COPY_AND_ASSIGN(RemoteMediaStreamImpl); |
| 47 }; | 47 }; |
| 48 | 48 |
| 49 } // namespace content | 49 } // namespace content |
| 50 | 50 |
| 51 #endif // CONTENT_RENDERER_MEDIA_REMOTE_MEDIA_STREAM_IMPL_H_ | 51 #endif // CONTENT_RENDERER_MEDIA_REMOTE_MEDIA_STREAM_IMPL_H_ |
| OLD | NEW |