 Chromium Code Reviews
 Chromium Code Reviews Issue 3000693003:
  Move kMinPixelsPerFrame constant in VideoStreamEncoder to VideoEncoder::ScalingSettings.  (Closed)
    
  
    Issue 3000693003:
  Move kMinPixelsPerFrame constant in VideoStreamEncoder to VideoEncoder::ScalingSettings.  (Closed) 
  | OLD | NEW | 
|---|---|
| 1 /* | 1 /* | 
| 2 * Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2017 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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 57 h264_settings.ppsLen = 0; | 57 h264_settings.ppsLen = 0; | 
| 58 h264_settings.profile = H264::kProfileConstrainedBaseline; | 58 h264_settings.profile = H264::kProfileConstrainedBaseline; | 
| 59 | 59 | 
| 60 return h264_settings; | 60 return h264_settings; | 
| 61 } | 61 } | 
| 62 | 62 | 
| 63 VideoEncoder::ScalingSettings::ScalingSettings(bool on, int low, int high) | 63 VideoEncoder::ScalingSettings::ScalingSettings(bool on, int low, int high) | 
| 64 : enabled(on), | 64 : enabled(on), | 
| 65 thresholds(rtc::Optional<QpThresholds>(QpThresholds(low, high))) {} | 65 thresholds(rtc::Optional<QpThresholds>(QpThresholds(low, high))) {} | 
| 66 | 66 | 
| 67 VideoEncoder::ScalingSettings::ScalingSettings(bool on, | |
| 68 int low, | |
| 69 int high, | |
| 70 int min_pixels) | |
| 71 : enabled(on), | |
| 72 thresholds(rtc::Optional<QpThresholds>(QpThresholds(low, high))), | |
| 
kthelgason
2017/08/16 13:42:22
i prefer to defer to the other constructor when po
 | |
| 73 min_pixels_per_frame(min_pixels) {} | |
| 74 | |
| 75 VideoEncoder::ScalingSettings::ScalingSettings(bool on, int min_pixels) | |
| 76 : enabled(on), min_pixels_per_frame(min_pixels) {} | |
| 
kthelgason
2017/08/16 13:42:22
same here.
 | |
| 77 | |
| 67 VideoEncoder::ScalingSettings::ScalingSettings(bool on) : enabled(on) {} | 78 VideoEncoder::ScalingSettings::ScalingSettings(bool on) : enabled(on) {} | 
| 68 | 79 | 
| 69 VideoEncoder::ScalingSettings::~ScalingSettings() {} | 80 VideoEncoder::ScalingSettings::~ScalingSettings() {} | 
| 70 | 81 | 
| 71 | 82 | 
| 72 int32_t VideoEncoder::SetRates(uint32_t bitrate, uint32_t framerate) { | 83 int32_t VideoEncoder::SetRates(uint32_t bitrate, uint32_t framerate) { | 
| 73 RTC_NOTREACHED() << "SetRate(uint32_t, uint32_t) is deprecated."; | 84 RTC_NOTREACHED() << "SetRate(uint32_t, uint32_t) is deprecated."; | 
| 74 return -1; | 85 return -1; | 
| 75 } | 86 } | 
| 76 | 87 | 
| (...skipping 12 matching lines...) Expand all Loading... | |
| 89 } | 100 } | 
| 90 | 101 | 
| 91 bool VideoEncoder::SupportsNativeHandle() const { | 102 bool VideoEncoder::SupportsNativeHandle() const { | 
| 92 return false; | 103 return false; | 
| 93 } | 104 } | 
| 94 | 105 | 
| 95 const char* VideoEncoder::ImplementationName() const { | 106 const char* VideoEncoder::ImplementationName() const { | 
| 96 return "unknown"; | 107 return "unknown"; | 
| 97 } | 108 } | 
| 98 } // namespace webrtc | 109 } // namespace webrtc | 
| OLD | NEW |