| 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/api/rtpsenderinterface.h" | 14 #include "webrtc/api/rtpsenderinterface.h" |
| 15 #include "webrtc/base/basictypes.h" | 15 #include "webrtc/base/basictypes.h" |
| 16 #include "webrtc/base/scoped_ptr.h" | 16 #include "webrtc/base/scoped_ptr.h" |
| 17 #include "webrtc/media/base/videosinkinterface.h" | 17 #include "webrtc/media/base/videosinkinterface.h" |
| 18 #include "webrtc/media/base/videosourceinterface.h" |
| 18 | 19 |
| 19 namespace cricket { | 20 namespace cricket { |
| 20 | 21 |
| 21 class AudioSource; | 22 class AudioSource; |
| 22 class VideoCapturer; | |
| 23 class VideoFrame; | 23 class VideoFrame; |
| 24 class VideoRenderer; | |
| 25 struct AudioOptions; | 24 struct AudioOptions; |
| 26 struct VideoOptions; | 25 struct VideoOptions; |
| 27 | 26 |
| 28 } // namespace cricket | 27 } // namespace cricket |
| 29 | 28 |
| 30 namespace webrtc { | 29 namespace webrtc { |
| 31 | 30 |
| 32 class AudioSinkInterface; | 31 class AudioSinkInterface; |
| 33 | 32 |
| 34 // TODO(deadbeef): Change the key from an ssrc to a "sender_id" or | 33 // TODO(deadbeef): Change the key from an ssrc to a "sender_id" or |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 const RtpParameters& parameters) = 0; | 67 const RtpParameters& parameters) = 0; |
| 69 | 68 |
| 70 protected: | 69 protected: |
| 71 virtual ~AudioProviderInterface() {} | 70 virtual ~AudioProviderInterface() {} |
| 72 }; | 71 }; |
| 73 | 72 |
| 74 // This interface is called by VideoRtpSender/Receivers to change the settings | 73 // This interface is called by VideoRtpSender/Receivers to change the settings |
| 75 // of a video track connected to a certain PeerConnection. | 74 // of a video track connected to a certain PeerConnection. |
| 76 class VideoProviderInterface { | 75 class VideoProviderInterface { |
| 77 public: | 76 public: |
| 78 virtual bool SetCaptureDevice(uint32_t ssrc, | 77 virtual bool SetSource( |
| 79 cricket::VideoCapturer* camera) = 0; | 78 uint32_t ssrc, |
| 79 rtc::VideoSourceInterface<cricket::VideoFrame>* source) = 0; |
| 80 // Enable/disable the video playout of a remote video track with |ssrc|. | 80 // Enable/disable the video playout of a remote video track with |ssrc|. |
| 81 virtual void SetVideoPlayout( | 81 virtual void SetVideoPlayout( |
| 82 uint32_t ssrc, | 82 uint32_t ssrc, |
| 83 bool enable, | 83 bool enable, |
| 84 rtc::VideoSinkInterface<cricket::VideoFrame>* sink) = 0; | 84 rtc::VideoSinkInterface<cricket::VideoFrame>* sink) = 0; |
| 85 // Enable sending video on the local video track with |ssrc|. | 85 // Enable sending video on the local video track with |ssrc|. |
| 86 virtual void SetVideoSend(uint32_t ssrc, | 86 virtual void SetVideoSend(uint32_t ssrc, |
| 87 bool enable, | 87 bool enable, |
| 88 const cricket::VideoOptions* options) = 0; | 88 const cricket::VideoOptions* options) = 0; |
| 89 | 89 |
| 90 virtual RtpParameters GetVideoRtpParameters(uint32_t ssrc) const = 0; | 90 virtual RtpParameters GetVideoRtpParameters(uint32_t ssrc) const = 0; |
| 91 virtual bool SetVideoRtpParameters(uint32_t ssrc, | 91 virtual bool SetVideoRtpParameters(uint32_t ssrc, |
| 92 const RtpParameters& parameters) = 0; | 92 const RtpParameters& parameters) = 0; |
| 93 | 93 |
| 94 protected: | 94 protected: |
| 95 virtual ~VideoProviderInterface() {} | 95 virtual ~VideoProviderInterface() {} |
| 96 }; | 96 }; |
| 97 | 97 |
| 98 } // namespace webrtc | 98 } // namespace webrtc |
| 99 | 99 |
| 100 #endif // WEBRTC_API_MEDIASTREAMPROVIDER_H_ | 100 #endif // WEBRTC_API_MEDIASTREAMPROVIDER_H_ |
| OLD | NEW |