OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #ifndef WEBRTC_API_MEDIASTREAMPROVIDER_H_ | 11 #ifndef WEBRTC_API_MEDIASTREAMPROVIDER_H_ |
12 #define WEBRTC_API_MEDIASTREAMPROVIDER_H_ | 12 #define WEBRTC_API_MEDIASTREAMPROVIDER_H_ |
13 | 13 |
14 #include "webrtc/base/basictypes.h" | 14 #include "webrtc/base/basictypes.h" |
15 #include "webrtc/base/scoped_ptr.h" | 15 #include "webrtc/base/scoped_ptr.h" |
16 #include "webrtc/media/base/videosinkinterface.h" | 16 #include "webrtc/media/base/videosinkinterface.h" |
| 17 #include "webrtc/media/base/videosourceinterface.h" |
17 | 18 |
18 namespace cricket { | 19 namespace cricket { |
19 | 20 |
20 class AudioRenderer; | 21 class AudioRenderer; |
21 class VideoCapturer; | |
22 class VideoFrame; | 22 class VideoFrame; |
23 class VideoRenderer; | |
24 struct AudioOptions; | 23 struct AudioOptions; |
25 struct VideoOptions; | 24 struct VideoOptions; |
26 | 25 |
27 } // namespace cricket | 26 } // namespace cricket |
28 | 27 |
29 namespace webrtc { | 28 namespace webrtc { |
30 | 29 |
31 class AudioSinkInterface; | 30 class AudioSinkInterface; |
32 | 31 |
33 // TODO(deadbeef): Change the key from an ssrc to a "sender_id" or | 32 // TODO(deadbeef): Change the key from an ssrc to a "sender_id" or |
(...skipping 29 matching lines...) Expand all Loading... |
63 rtc::scoped_ptr<webrtc::AudioSinkInterface> sink) = 0; | 62 rtc::scoped_ptr<webrtc::AudioSinkInterface> sink) = 0; |
64 | 63 |
65 protected: | 64 protected: |
66 virtual ~AudioProviderInterface() {} | 65 virtual ~AudioProviderInterface() {} |
67 }; | 66 }; |
68 | 67 |
69 // This interface is called by VideoRtpSender/Receivers to change the settings | 68 // This interface is called by VideoRtpSender/Receivers to change the settings |
70 // of a video track connected to a certain PeerConnection. | 69 // of a video track connected to a certain PeerConnection. |
71 class VideoProviderInterface { | 70 class VideoProviderInterface { |
72 public: | 71 public: |
73 virtual bool SetCaptureDevice(uint32_t ssrc, | 72 virtual bool SetSource( |
74 cricket::VideoCapturer* camera) = 0; | 73 uint32_t ssrc, |
| 74 rtc::VideoSourceInterface<cricket::VideoFrame>* source) = 0; |
75 // Enable/disable the video playout of a remote video track with |ssrc|. | 75 // Enable/disable the video playout of a remote video track with |ssrc|. |
76 virtual void SetVideoPlayout( | 76 virtual void SetVideoPlayout( |
77 uint32_t ssrc, | 77 uint32_t ssrc, |
78 bool enable, | 78 bool enable, |
79 rtc::VideoSinkInterface<cricket::VideoFrame>* sink) = 0; | 79 rtc::VideoSinkInterface<cricket::VideoFrame>* sink) = 0; |
80 // Enable sending video on the local video track with |ssrc|. | 80 // Enable sending video on the local video track with |ssrc|. |
81 virtual void SetVideoSend(uint32_t ssrc, | 81 virtual void SetVideoSend(uint32_t ssrc, |
82 bool enable, | 82 bool enable, |
83 const cricket::VideoOptions* options) = 0; | 83 const cricket::VideoOptions* options) = 0; |
84 | 84 |
85 protected: | 85 protected: |
86 virtual ~VideoProviderInterface() {} | 86 virtual ~VideoProviderInterface() {} |
87 }; | 87 }; |
88 | 88 |
89 } // namespace webrtc | 89 } // namespace webrtc |
90 | 90 |
91 #endif // WEBRTC_API_MEDIASTREAMPROVIDER_H_ | 91 #endif // WEBRTC_API_MEDIASTREAMPROVIDER_H_ |
OLD | NEW |