| OLD | NEW |
| 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 585 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 596 SetStreamState(send_stream, stream_idx); | 596 SetStreamState(send_stream, stream_idx); |
| 597 configurations_[i].rc_target_bitrate = stream_bitrate; | 597 configurations_[i].rc_target_bitrate = stream_bitrate; |
| 598 temporal_layers_[stream_idx]->ConfigureBitrates(stream_bitrate, | 598 temporal_layers_[stream_idx]->ConfigureBitrates(stream_bitrate, |
| 599 inst->maxBitrate, | 599 inst->maxBitrate, |
| 600 inst->maxFramerate, | 600 inst->maxFramerate, |
| 601 &configurations_[i]); | 601 &configurations_[i]); |
| 602 } | 602 } |
| 603 } | 603 } |
| 604 | 604 |
| 605 rps_.Init(); | 605 rps_.Init(); |
| 606 quality_scaler_.Init(codec_.qpMax / kDefaultLowQpDenominator); | 606 quality_scaler_.Init(codec_.qpMax / QualityScaler::kDefaultLowQpDenominator); |
| 607 quality_scaler_.ReportFramerate(codec_.maxFramerate); | 607 quality_scaler_.ReportFramerate(codec_.maxFramerate); |
| 608 | 608 |
| 609 return InitAndSetControlSettings(); | 609 return InitAndSetControlSettings(); |
| 610 } | 610 } |
| 611 | 611 |
| 612 int VP8EncoderImpl::SetCpuSpeed(int width, int height) { | 612 int VP8EncoderImpl::SetCpuSpeed(int width, int height) { |
| 613 #if defined(WEBRTC_ARCH_ARM) || defined(WEBRTC_ARCH_ARM64) | 613 #if defined(WEBRTC_ARCH_ARM) || defined(WEBRTC_ARCH_ARM64) |
| 614 // On mobile platform, always set to -12 to leverage between cpu usage | 614 // On mobile platform, always set to -12 to leverage between cpu usage |
| 615 // and video quality. | 615 // and video quality. |
| 616 return -12; | 616 return -12; |
| (...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1395 return -1; | 1395 return -1; |
| 1396 } | 1396 } |
| 1397 if (vpx_codec_control(copy->decoder_, VP8_SET_REFERENCE, ref_frame_) | 1397 if (vpx_codec_control(copy->decoder_, VP8_SET_REFERENCE, ref_frame_) |
| 1398 != VPX_CODEC_OK) { | 1398 != VPX_CODEC_OK) { |
| 1399 return -1; | 1399 return -1; |
| 1400 } | 1400 } |
| 1401 return 0; | 1401 return 0; |
| 1402 } | 1402 } |
| 1403 | 1403 |
| 1404 } // namespace webrtc | 1404 } // namespace webrtc |
| OLD | NEW |