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

Side by Side Diff: webrtc/modules/video_coding/qm_select.h

Issue 1935753002: Revert of Remove VCMQmRobustness. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 7 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 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
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 EncoderState encoder_state_; 315 EncoderState encoder_state_;
316 ResolutionAction action_; 316 ResolutionAction action_;
317 // Short history of the down-sampling actions from the Initialize() state. 317 // Short history of the down-sampling actions from the Initialize() state.
318 // This is needed for going up in resolution. Since the total amount of 318 // This is needed for going up in resolution. Since the total amount of
319 // down-sampling actions are constrained, the length of the list need not be 319 // down-sampling actions are constrained, the length of the list need not be
320 // large: i.e., (4/3) ^{kDownActionHistorySize} <= kMaxDownSample. 320 // large: i.e., (4/3) ^{kDownActionHistorySize} <= kMaxDownSample.
321 ResolutionAction down_action_history_[kDownActionHistorySize]; 321 ResolutionAction down_action_history_[kDownActionHistorySize];
322 int num_layers_; 322 int num_layers_;
323 }; 323 };
324 324
325 // Robustness settings class.
326
327 class VCMQmRobustness : public VCMQmMethod {
328 public:
329 VCMQmRobustness();
330 ~VCMQmRobustness();
331
332 virtual void Reset();
333
334 // Adjust FEC rate based on content: every ~1 sec from SetTargetRates.
335 // Returns an adjustment factor.
336 float AdjustFecFactor(uint8_t code_rate_delta,
337 float total_rate,
338 float framerate,
339 int64_t rtt_time,
340 uint8_t packet_loss);
341
342 // Set the UEP protection on/off.
343 bool SetUepProtection(uint8_t code_rate_delta,
344 float total_rate,
345 uint8_t packet_loss,
346 bool frame_type);
347
348 private:
349 // Previous state of network parameters.
350 float prev_total_rate_;
351 int64_t prev_rtt_time_;
352 uint8_t prev_packet_loss_;
353 uint8_t prev_code_rate_delta_;
354 };
325 } // namespace webrtc 355 } // namespace webrtc
326 #endif // WEBRTC_MODULES_VIDEO_CODING_QM_SELECT_H_ 356 #endif // WEBRTC_MODULES_VIDEO_CODING_QM_SELECT_H_
OLDNEW
« no previous file with comments | « webrtc/modules/video_coding/media_optimization.cc ('k') | webrtc/modules/video_coding/qm_select.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698