Revert of Modify profiles for H264 encode SW fallback (patchset #2 id:20001 of https://codereview.webrtc.org/2997913003/ )
Reason for revert:
Breaks the internal bots.
Root cause: The "public_deps" is defined behind an "if" condition which may not be true.
Original issue's description:
> Modify profiles for H264 encode SW fallback
>
> We have only Constrained Baseline profile available in SW encoder impl
> so modify the profile to that in case of a fallback
>
> BUG=chromium:735959
>
> Review-Url: https://codereview.webrtc.org/2997913003
> Cr-Commit-Position: refs/heads/master@{#19436}
> Committed: 1fd66656b3
TBR=magjed@webrtc.org,emircan@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:735959
Review-Url: https://codereview.webrtc.org/2995373002
Cr-Commit-Position: refs/heads/master@{#19438}
This commit is contained in:
@ -112,6 +112,7 @@ rtc_static_library("rtc_media_base") {
|
||||
}
|
||||
|
||||
deps += [
|
||||
":rtc_h264_profile_id",
|
||||
"..:webrtc_common",
|
||||
"../api:libjingle_peerconnection_api",
|
||||
"../p2p",
|
||||
@ -119,8 +120,6 @@ rtc_static_library("rtc_media_base") {
|
||||
"../rtc_base:rtc_base_approved",
|
||||
]
|
||||
|
||||
public_deps += [ ":rtc_h264_profile_id" ]
|
||||
|
||||
if (is_nacl) {
|
||||
deps += [ "//native_client_sdk/src/libraries/nacl_io" ]
|
||||
}
|
||||
|
||||
@ -10,7 +10,6 @@
|
||||
|
||||
#include "webrtc/media/engine/videoencodersoftwarefallbackwrapper.h"
|
||||
|
||||
#include "webrtc/media/base/h264_profile_level_id.h"
|
||||
#include "webrtc/media/engine/internalencoderfactory.h"
|
||||
#include "webrtc/modules/video_coding/include/video_error_codes.h"
|
||||
#include "webrtc/rtc_base/checks.h"
|
||||
@ -90,7 +89,6 @@ VideoEncoderSoftwareFallbackWrapper::VideoEncoderSoftwareFallbackWrapper(
|
||||
}
|
||||
|
||||
bool VideoEncoderSoftwareFallbackWrapper::InitFallbackEncoder() {
|
||||
MaybeModifyCodecForFallback();
|
||||
cricket::InternalEncoderFactory internal_factory;
|
||||
if (!FindMatchingCodec(internal_factory.supported_codecs(), codec_)) {
|
||||
LOG(LS_WARNING)
|
||||
@ -357,13 +355,4 @@ bool VideoEncoderSoftwareFallbackWrapper::ForcedFallbackParams::ShouldStop(
|
||||
(codec.width * codec.height >= kMinPixelsStop);
|
||||
}
|
||||
|
||||
void VideoEncoderSoftwareFallbackWrapper::MaybeModifyCodecForFallback() {
|
||||
// We have a specific case for H264 ConstrainedBaseline because that is the
|
||||
// only supported profile in Sw fallback.
|
||||
if (!cricket::CodecNamesEq(codec_.name.c_str(), cricket::kH264CodecName))
|
||||
return;
|
||||
codec_.SetParam(cricket::kH264FmtpProfileLevelId,
|
||||
cricket::kH264ProfileLevelConstrainedBaseline);
|
||||
}
|
||||
|
||||
} // namespace webrtc
|
||||
|
||||
@ -77,7 +77,6 @@ class VideoEncoderSoftwareFallbackWrapper : public VideoEncoder {
|
||||
bool TryReInitForcedFallbackEncoder();
|
||||
void ValidateSettingsForForcedFallback();
|
||||
bool IsForcedFallbackActive() const;
|
||||
void MaybeModifyCodecForFallback();
|
||||
|
||||
// Settings used in the last InitEncode call and used if a dynamic fallback to
|
||||
// software is required.
|
||||
@ -95,7 +94,7 @@ class VideoEncoderSoftwareFallbackWrapper : public VideoEncoder {
|
||||
uint32_t packet_loss_;
|
||||
int64_t rtt_;
|
||||
|
||||
cricket::VideoCodec codec_;
|
||||
const cricket::VideoCodec codec_;
|
||||
webrtc::VideoEncoder* const encoder_;
|
||||
|
||||
std::unique_ptr<webrtc::VideoEncoder> fallback_encoder_;
|
||||
|
||||
Reference in New Issue
Block a user