Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(46)

Side by Side Diff: webrtc/video_send_stream.h

Issue 2923563002: Add field trial for balanced degradation preference. (Closed)
Patch Set: rebase Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « webrtc/media/engine/webrtcvideoengine_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 217
218 // Based on the spec in 218 // Based on the spec in
219 // https://w3c.github.io/webrtc-pc/#idl-def-rtcdegradationpreference. 219 // https://w3c.github.io/webrtc-pc/#idl-def-rtcdegradationpreference.
220 // These options are enforced on a best-effort basis. For instance, all of 220 // These options are enforced on a best-effort basis. For instance, all of
221 // these options may suffer some frame drops in order to avoid queuing. 221 // these options may suffer some frame drops in order to avoid queuing.
222 // TODO(sprang): Look into possibility of more strictly enforcing the 222 // TODO(sprang): Look into possibility of more strictly enforcing the
223 // maintain-framerate option. 223 // maintain-framerate option.
224 enum class DegradationPreference { 224 enum class DegradationPreference {
225 // Don't take any actions based on over-utilization signals. 225 // Don't take any actions based on over-utilization signals.
226 kDegradationDisabled, 226 kDegradationDisabled,
227 // On over-use, request lost resolution, possibly causing down-scaling. 227 // On over-use, request lower frame rate, possibly causing frame drops.
228 kMaintainResolution, 228 kMaintainResolution,
229 // On over-use, request lower frame rate, possible causing frame drops. 229 // On over-use, request lower resolution, possibly causing down-scaling.
230 kMaintainFramerate, 230 kMaintainFramerate,
231 // Try to strike a "pleasing" balance between frame rate or resolution. 231 // Try to strike a "pleasing" balance between frame rate or resolution.
232 kBalanced, 232 kBalanced,
233 }; 233 };
234 234
235 virtual void SetSource( 235 virtual void SetSource(
236 rtc::VideoSourceInterface<webrtc::VideoFrame>* source, 236 rtc::VideoSourceInterface<webrtc::VideoFrame>* source,
237 const DegradationPreference& degradation_preference) = 0; 237 const DegradationPreference& degradation_preference) = 0;
238 238
239 // Set which streams to send. Must have at least as many SSRCs as configured 239 // Set which streams to send. Must have at least as many SSRCs as configured
(...skipping 19 matching lines...) Expand all
259 EnableEncodedFrameRecording(std::vector<rtc::PlatformFile>(), 0); 259 EnableEncodedFrameRecording(std::vector<rtc::PlatformFile>(), 0);
260 } 260 }
261 261
262 protected: 262 protected:
263 virtual ~VideoSendStream() {} 263 virtual ~VideoSendStream() {}
264 }; 264 };
265 265
266 } // namespace webrtc 266 } // namespace webrtc
267 267
268 #endif // WEBRTC_VIDEO_SEND_STREAM_H_ 268 #endif // WEBRTC_VIDEO_SEND_STREAM_H_
OLDNEW
« no previous file with comments | « webrtc/media/engine/webrtcvideoengine_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698