OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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_VIDEO_SEND_STREAM_H_ | 11 #ifndef WEBRTC_VIDEO_SEND_STREAM_H_ |
12 #define WEBRTC_VIDEO_SEND_STREAM_H_ | 12 #define WEBRTC_VIDEO_SEND_STREAM_H_ |
13 | 13 |
14 #include <map> | 14 #include <map> |
15 #include <string> | 15 #include <string> |
16 | 16 |
17 #include "webrtc/common_types.h" | 17 #include "webrtc/common_types.h" |
18 #include "webrtc/config.h" | 18 #include "webrtc/config.h" |
19 #include "webrtc/frame_callback.h" | 19 #include "webrtc/frame_callback.h" |
| 20 #include "webrtc/media/base/videosinkinterface.h" |
20 #include "webrtc/stream.h" | 21 #include "webrtc/stream.h" |
21 #include "webrtc/transport.h" | 22 #include "webrtc/transport.h" |
22 #include "webrtc/media/base/videosinkinterface.h" | 23 #include "webrtc/media/base/videosinkinterface.h" |
23 | 24 |
24 namespace webrtc { | 25 namespace webrtc { |
25 | 26 |
26 class LoadObserver; | 27 class LoadObserver; |
27 class VideoEncoder; | 28 class VideoEncoder; |
28 | 29 |
29 // Class to deliver captured frame to the video send stream. | 30 // Class to deliver captured frame to the video send stream. |
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
132 | 133 |
133 // Transport for outgoing packets. | 134 // Transport for outgoing packets. |
134 Transport* send_transport = nullptr; | 135 Transport* send_transport = nullptr; |
135 | 136 |
136 // Callback for overuse and normal usage based on the jitter of incoming | 137 // Callback for overuse and normal usage based on the jitter of incoming |
137 // captured frames. 'nullptr' disables the callback. | 138 // captured frames. 'nullptr' disables the callback. |
138 LoadObserver* overuse_callback = nullptr; | 139 LoadObserver* overuse_callback = nullptr; |
139 | 140 |
140 // Called for each I420 frame before encoding the frame. Can be used for | 141 // Called for each I420 frame before encoding the frame. Can be used for |
141 // effects, snapshots etc. 'nullptr' disables the callback. | 142 // effects, snapshots etc. 'nullptr' disables the callback. |
142 I420FrameCallback* pre_encode_callback = nullptr; | 143 rtc::VideoSinkInterface<VideoFrame>* pre_encode_callback = nullptr; |
143 | 144 |
144 // Called for each encoded frame, e.g. used for file storage. 'nullptr' | 145 // Called for each encoded frame, e.g. used for file storage. 'nullptr' |
145 // disables the callback. Also measures timing and passes the time | 146 // disables the callback. Also measures timing and passes the time |
146 // spent on encoding. This timing will not fire if encoding takes longer | 147 // spent on encoding. This timing will not fire if encoding takes longer |
147 // than the measuring window, since the sample data will have been dropped. | 148 // than the measuring window, since the sample data will have been dropped. |
148 EncodedFrameObserver* post_encode_callback = nullptr; | 149 EncodedFrameObserver* post_encode_callback = nullptr; |
149 | 150 |
150 // Renderer for local preview. The local renderer will be called even if | 151 // Renderer for local preview. The local renderer will be called even if |
151 // sending hasn't started. 'nullptr' disables local rendering. | 152 // sending hasn't started. 'nullptr' disables local rendering. |
152 rtc::VideoSinkInterface<VideoFrame>* local_renderer = nullptr; | 153 rtc::VideoSinkInterface<VideoFrame>* local_renderer = nullptr; |
(...skipping 21 matching lines...) Expand all Loading... |
174 // in the config. Encoder settings are passed on to the encoder instance along | 175 // in the config. Encoder settings are passed on to the encoder instance along |
175 // with the VideoStream settings. | 176 // with the VideoStream settings. |
176 virtual void ReconfigureVideoEncoder(const VideoEncoderConfig& config) = 0; | 177 virtual void ReconfigureVideoEncoder(const VideoEncoderConfig& config) = 0; |
177 | 178 |
178 virtual Stats GetStats() = 0; | 179 virtual Stats GetStats() = 0; |
179 }; | 180 }; |
180 | 181 |
181 } // namespace webrtc | 182 } // namespace webrtc |
182 | 183 |
183 #endif // WEBRTC_VIDEO_SEND_STREAM_H_ | 184 #endif // WEBRTC_VIDEO_SEND_STREAM_H_ |
OLD | NEW |