OLD | NEW |
---|---|
(Empty) | |
1 // Copyright (c) 2017 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_RTC_RTP_RECEIVER_H_ | |
6 #define CONTENT_RENDERER_MEDIA_WEBRTC_RTC_RTP_RECEIVER_H_ | |
7 | |
8 #include "base/memory/ref_counted.h" | |
9 #include "content/common/content_export.h" | |
10 #include "third_party/WebKit/public/platform/WebMediaStreamTrack.h" | |
11 #include "third_party/WebKit/public/platform/WebRTCRtpReceiver.h" | |
12 #include "third_party/webrtc/api/rtpreceiverinterface.h" | |
13 | |
14 namespace content { | |
15 | |
16 // Used to surface |webrtc::RtpReceiverInterface| to blink. Multiple | |
17 // |RTCRtpReceiver|s could reference the same webrtc receiver; |id| is the value | |
18 // of the pointer to the webrtc receiver. | |
19 class CONTENT_EXPORT RTCRtpReceiver : public blink::WebRTCRtpReceiver { | |
20 public: | |
21 static uintptr_t getId( | |
22 const webrtc::RtpReceiverInterface* webrtc_rtp_receiver); | |
23 | |
24 RTCRtpReceiver(webrtc::RtpReceiverInterface* webrtc_rtp_receiver, | |
25 const blink::WebMediaStreamTrack& web_track); | |
26 ~RTCRtpReceiver() override; | |
27 | |
28 uintptr_t id() const override; | |
29 | |
30 const blink::WebMediaStreamTrack& track() const override; | |
31 const webrtc::MediaStreamTrackInterface& webrtc_track() const; | |
32 | |
33 private: | |
34 const scoped_refptr<webrtc::RtpReceiverInterface> webrtc_rtp_receiver_; | |
35 const blink::WebMediaStreamTrack web_track_; | |
36 }; | |
jochen (gone - plz use gerrit)
2017/03/30 11:53:38
disallow copy/assign
hbos_chromium
2017/03/30 12:04:32
Done.
| |
37 | |
38 } // namespace content | |
39 | |
40 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_RTC_RTP_RECEIVER_H_ | |
OLD | NEW |