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

Side by Side Diff: webrtc/sdk/objc/Framework/Classes/VideoToolbox/encoder.mm

Issue 2991123002: ObjC: Fix quality scaling for injected encoders (Closed)
Patch Set: Created 3 years, 4 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) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 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 739 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 750
751 EncodedImageCallback::Result res = 751 EncodedImageCallback::Result res =
752 callback_->OnEncodedImage(frame, &codec_specific_info, header.get()); 752 callback_->OnEncodedImage(frame, &codec_specific_info, header.get());
753 if (res.error != EncodedImageCallback::Result::OK) { 753 if (res.error != EncodedImageCallback::Result::OK) {
754 LOG(LS_ERROR) << "Encode callback failed: " << res.error; 754 LOG(LS_ERROR) << "Encode callback failed: " << res.error;
755 return; 755 return;
756 } 756 }
757 bitrate_adjuster_.Update(frame._length); 757 bitrate_adjuster_.Update(frame._length);
758 } 758 }
759 759
760 // TODO(magjed): This function is not used by RTCVideoEncoderH264, but this whol e file will be
761 // removed soon and inlined as ObjC.
760 VideoEncoder::ScalingSettings H264VideoToolboxEncoder::GetScalingSettings() 762 VideoEncoder::ScalingSettings H264VideoToolboxEncoder::GetScalingSettings()
761 const { 763 const {
762 return VideoEncoder::ScalingSettings(true, internal::kLowH264QpThreshold, 764 return VideoEncoder::ScalingSettings(true, internal::kLowH264QpThreshold,
763 internal::kHighH264QpThreshold); 765 internal::kHighH264QpThreshold);
764 } 766 }
765 } // namespace webrtc 767 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698