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

Side by Side Diff: webrtc/modules/video_coding/utility/quality_scaler_unittest.cc

Issue 1894083002: Tune QP-based quality thresholds. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 8 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/modules/video_coding/utility/quality_scaler.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) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 11 matching lines...) Expand all
22 static const int kHeightVga = 480; 22 static const int kHeightVga = 480;
23 static const int kFramerate = 30; 23 static const int kFramerate = 30;
24 static const int kLowQp = 15; 24 static const int kLowQp = 15;
25 static const int kNormalQp = 30; 25 static const int kNormalQp = 30;
26 static const int kLowQpThreshold = 18; 26 static const int kLowQpThreshold = 18;
27 static const int kHighQp = 40; 27 static const int kHighQp = 40;
28 static const int kDisabledBadQpThreshold = 64; 28 static const int kDisabledBadQpThreshold = 64;
29 static const int kLowInitialBitrateKbps = 300; 29 static const int kLowInitialBitrateKbps = 300;
30 // These values need to be in sync with corresponding constants 30 // These values need to be in sync with corresponding constants
31 // in quality_scaler.cc 31 // in quality_scaler.cc
32 static const int kMeasureSecondsDownscale = 3;
33 static const int kMeasureSecondsFastUpscale = 2; 32 static const int kMeasureSecondsFastUpscale = 2;
34 static const int kMeasureSecondsUpscale = 5; 33 static const int kMeasureSecondsUpscale = 5;
34 static const int kMeasureSecondsDownscale = 5;
35 static const int kMinDownscaleDimension = 140; 35 static const int kMinDownscaleDimension = 140;
36 } // namespace 36 } // namespace
37 37
38 class QualityScalerTest : public ::testing::Test { 38 class QualityScalerTest : public ::testing::Test {
39 public: 39 public:
40 // Temporal and spatial resolution. 40 // Temporal and spatial resolution.
41 struct Resolution { 41 struct Resolution {
42 int framerate; 42 int framerate;
43 int width; 43 int width;
44 int height; 44 int height;
(...skipping 443 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 488
489 TEST_F(QualityScalerTest, DownscalesFrom1280x720To320x180) { 489 TEST_F(QualityScalerTest, DownscalesFrom1280x720To320x180) {
490 DownscaleEndsAt(1280, 720, 320, 180); 490 DownscaleEndsAt(1280, 720, 320, 180);
491 } 491 }
492 492
493 TEST_F(QualityScalerTest, DoesntDownscaleInitialQvga) { 493 TEST_F(QualityScalerTest, DoesntDownscaleInitialQvga) {
494 DownscaleEndsAt(320, 180, 320, 180); 494 DownscaleEndsAt(320, 180, 320, 180);
495 } 495 }
496 496
497 } // namespace webrtc 497 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/video_coding/utility/quality_scaler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698